コード例 #1
0
    /// <summary>
    /// Set whether the game is currently paused, invoking OnIsPausedChange if a new value is given
    /// </summary>
    public void SetIsPaused(bool _isPaused)
    {
        if (isPaused != _isPaused)
        {
            isPaused = _isPaused;

            OnIsPausedChange?.Invoke();
        }
    }
コード例 #2
0
 /// <summary>
 /// Editor-specific function called by Odin when the isPaused value is changed in Unity Inspector to invoke the OnIsPausedChange event
 /// </summary>
 private void EditorUpdateIsPaused()
 {
     OnIsPausedChange?.Invoke();
 }