void OnDisable() { GamePlay.instance.StartCoroutine("LoseTime"); BGMusicController.instance.StartBGMusic(); EGTween.Resume(GamePlay.instance.gameObject, true); GameController.instance.isGamePaused = false; }
public void TogglePauseGame(bool paused) { isGamePaused = paused; if (GamePlayMode == GameMode.timer) { if (isGamePaused) { EGTween.Pause(gameObject); } else { EGTween.Resume(gameObject); } } }
/// <summary> /// Raises the disable event. /// </summary> void OnDisable() { BGMusicController.instance.StartBGMusic(); EGTween.Resume(GamePlay.instance.gameObject, true); GameController.instance.isGamePaused = false; }