private void ResumeMusicAfterMenuClosed(OnMenuClosed data) { if (isPlayerInDungeon) { musicSpeaker.clip = dungeonMusic; musicSpeaker.PlayDelayed(2); musicSpeaker.loop = true; } else { musicSpeaker.clip = fightMusic; musicSpeaker.Play(); } }
public void CloseAll() { selected = false; if (dummyParent) { dummyParent.CloseAll(); Destroy(dummyParent.gameObject); dummyParent = null; if (OnMenuClosed != null) { OnMenuClosed.Invoke(); } } }
public void HideMenu() { if (_isLoading && ProjectData.GameMode != GameMode.View) { _openAfterLoad = false; Loader.StopLoaderAnimation(); return; } BrowserWindow.SetActive(false); OnMenuClosed?.Invoke(); ModeButton.SetActive(false); }
public void CloseAll() { selected = false; if (dummyParent) { dummyParent.CloseAll(); Destroy(dummyParent.gameObject); dummyParent = null; laserPointer.maxReticleDistance = reticleDistance; if (OnMenuClosed != null) { OnMenuClosed.Invoke(); } } }
/// <summary> /// Triggers the OnMenuClosed event. Should only be used by overrides of <see cref="CloseMenuRoutine"/> /// </summary> protected void InvokeOnMenuClosed() { OnMenuClosed?.Invoke(); }