Added logic to enforce game rules to board.js, exposed swap() and get_board() functions, these are only functions that can alter the state of the game board.