complete refactoring: everything handled in the game state machine