public void TogglePause() { GameClock c = GameClock.Instance(); if (c.isPaused) { c.Unpause(); } else { c.Pause(); } }
void Start() { #if UNITY_EDITOR onUnityEditorStart.Invoke(); #endif #if UNITY_WEBPLAYER onWebplayerStart.Invoke(); #endif #if UNITY_ANDROID || UNITY_IPHONE onMobileStart.Invoke(); #endif if (onPause != null) { GameClock.Instance().pauseEvents.onPause.AddListener(onPause.Invoke); } if (onUnpause != null) { GameClock.Instance().pauseEvents.onUnpause.AddListener(onUnpause.Invoke); } }
public void Unpause() { GameClock.Instance().Unpause(); }
public void Pause() { GameClock.Instance().Pause(); }