public void UnpauseGame() { isPaused = false; OnPauseEvent?.Invoke(isPaused); Time.timeScale = 1; pausePanel.SetActive(false); }
public void PauseGame() { isPaused = true; OnPauseEvent?.Invoke(isPaused); Time.timeScale = 0; pausePanel.SetActive(true); }
public void OnPause(InputAction.CallbackContext context) { if (!context.performed) { return; } OnPauseEvent?.Invoke(); }
void OnPause(OnPauseEvent e) { if (e.paused) { //Pauser.Pause(this.spriteObject); Pauser.Pause(this); } else { Pauser.Resume(this); //Pauser.Resume(this.spriteObject); } }
void OnPause(OnPauseEvent e) { if (e.paused) { Pauser.Pause(this); } else { Pauser.Resume(this); } }
void OnPause(OnPauseEvent e) { if (e.paused) { pauseTime = Time.time; Pauser.Pause(this); } else { nextAttackTime += Time.time - pauseTime; Pauser.Resume(this); } }
void OnPause(OnPauseEvent e) { // Pausing the game will push back the end time for the dialog. We'll // store how much time is left in the dialog in the endTime field, // and then restore the value when the game is unpaused. if (e.paused) { this.enabled = false; this.endTime -= Time.time; } else { this.enabled = true; this.endTime += Time.time; } }
void Start() { OnPause = new OnPauseEvent(); OnPlay = new OnPlayEvent(); OnMusicLoad = new OnMusicLoadEvent(); ViewRect = BaseWindow.WindowRectTransform; UiWidth = ViewRect.rect.width; if (LimSystem.ChartContainer == null) { return; } if (LimSystem.ChartContainer.ChartLoadResult.isBackgroundVideoDetected) { InitializeVideo(); return; } UsePreciseMode(); }
private void Pause(OnPauseEvent e) { if (e.paused) { activated = false; pauseStart = Time.time; } else { activated = true; float gap = Time.time - pauseStart; locationHistory.AddLast(CreateGapLocation(gap)); timeGap += gap; } }
private void Pause(OnPauseEvent e) { if (e.paused) { activated = false; pauseTime = Time.time; } else { activated = true; lastCharge += Time.time - pauseTime; } }
void OnPause(OnPauseEvent e) { if (e.paused) { walk.enabled = false; Pauser.Pause(this); } else { walk.enabled = true; Pauser.Resume(this); } }
void HandleOnPause(OnPauseEvent e) { _anim.SetTrigger("Pause"); }
public void EnablePauseCanvas(OnPauseEvent pause) { _pauseCanvas.enabled = true; }