implement game.