Пример #1
0
        public void OnPauseButton()
        {
            _GameState gameState = GameControl.GetGameState();

            if (gameState == _GameState.Over)
            {
                return;
            }

            if (toggleFastForward.isOn)
            {
                toggleFastForward.isOn = false;
            }

            if (gameState == _GameState.Pause)
            {
                GameControl.ResumeGame();
                UIPauseMenu.Hide();
            }
            else
            {
                GameControl.PauseGame();
                UIPauseMenu.Show();
            }
        }
Пример #2
0
        IEnumerator _ResumeGame()
        {
            Debug.Log("_ResumeGame");
            CameraControl.FadeBlur(uiBlurEffect, 2, 0);
            CameraControl.TurnBlurOff();
            GameControl.ResumeGame();
            UIPauseMenu.Hide();

            yield return(StartCoroutine(WaitForRealSeconds(0.25f)));
            //Time.timeScale=1;
        }