Cleaning up the code for the graphic version of the game.