Beispiel #1
0
    IEnumerator StartServiceCounterCoroutine()
    {
        yield return(delayServiceWaitForSeconds);

        currentBall  = Instantiate(ballPrefab);
        ballIsServed = true;
        GameStatusStatesFactory.GetGameStateMachine().ChangeGameStatus(GameStatusEnum.GameRunning);
    }
Beispiel #2
0
 void PauseUnpause()
 {
     isGamePaused = !isGamePaused;
     if (isGamePaused == true)
     {
         GameStatusStatesFactory.GetGameStateMachine().ChangeGameStatus(GameStatusEnum.GamePaused);
     }
     else
     {
         GameStatusStatesFactory.GetGameStateMachine().BackToPreviousState();
     }
 }
Beispiel #3
0
 private void GoHome()
 {
     Debug.Log("Back to Home");
     GameStatusStatesFactory.GetGameStateMachine().ChangeGameStatus(GameStatusEnum.ReadyToStart);
 }