예제 #1
0
    private void BackButtonAction()
    {
        switch (gameCoordinator.GetCurrentGameState())
        {
        case GameStates.gameIsRunning: {
            gameCoordinator.PauseGame();
            break;
        }

        case GameStates.gameIsPaused: {
            gameCoordinator.UnpauseGame();
            break;
        }

        case GameStates.gameIsOver: {
            gameCoordinator.RestartGame();
            break;
        }
        }
    }