game code moved to game.c