Added a bunch of game logic