public void OnFinished() { if (this.hBGMVolume != null) { this.hBGMVolume.Discard(); this.hBGMVolume = (MySound.VolumeHandle)null; } if (this.hVoiceVolume != null) { this.hVoiceVolume.Discard(); this.hVoiceVolume = (MySound.VolumeHandle)null; } if (this.AutoFade) { FadeController.Instance.FadeTo(Color.get_clear(), 1f, 0); } if (!string.IsNullOrEmpty(this.ReplayText)) { ((Behaviour)this).set_enabled(false); UIUtility.ConfirmBox(LocalizedText.Get(this.ReplayText), new UIUtility.DialogResultEvent(this.OnRetry), new UIUtility.DialogResultEvent(this.OnCancelReplay), (GameObject)null, true, -1); } else { this.ActivateOutputLinks(3); this.ActivateOutputLinks(5); ((Behaviour)this).set_enabled(false); } }
private void Play(string fileName) { ((Behaviour)this).set_enabled(true); this.hBGMVolume = new MySound.VolumeHandle(MySound.EType.BGM); this.hBGMVolume.SetVolume(0.0f, 0.0f); this.hVoiceVolume = new MySound.VolumeHandle(MySound.EType.VOICE); this.hVoiceVolume.SetVolume(0.0f, 0.0f); if (this.AutoFade) { SRPG_TouchInputModule.LockInput(); CriticalSection.Enter(CriticalSections.Default); FadeController.Instance.FadeTo(this.FadeColor, 1f, 0); this.StartCoroutine(this.PlayDelayed(fileName, new StreamingMovie.OnFinished(this.OnFinished))); } else { MonoSingleton <StreamingMovie> .Instance.Play(fileName, new StreamingMovie.OnFinished(this.OnFinished), (string)null); } }
public void Finished(bool is_replay = false) { if (this.hBGMVolume != null) { this.hBGMVolume.Discard(); this.hBGMVolume = (MySound.VolumeHandle)null; } if (this.hVoiceVolume != null) { this.hVoiceVolume.Discard(); this.hVoiceVolume = (MySound.VolumeHandle)null; } if (this.AutoFade) { SRPG_TouchInputModule.UnlockInput(false); CriticalSection.Leave(CriticalSections.Default); FadeController.Instance.FadeTo(Color.get_clear(), this.FadeTime, 0); } this.ActivateNext(); }
private void PlayMovie(string filename) { this.hBGMVolume = new MySound.VolumeHandle(MySound.EType.BGM); this.hBGMVolume.SetVolume(0.0f, 0.0f); this.hVoiceVolume = new MySound.VolumeHandle(MySound.EType.VOICE); this.hVoiceVolume.SetVolume(0.0f, 0.0f); if (this.AutoFade) { SRPG_TouchInputModule.LockInput(); CriticalSection.Enter(CriticalSections.Default); FadeController.Instance.FadeTo(this.FadeColor, this.FadeTime, 0); this.PlayFilename = filename; } else { MonoSingleton <StreamingMovie> .Instance.Play(filename, new StreamingMovie.OnFinished(this.Finished), "UI/FullScreenMovieDemo"); this.Played = true; } }