Working on the game logic.