// OVERRIDE METHODS: ---------------------------------------------------------------------- protected override IEnumerator RunItem() { yield return(this.RunShowText()); if (this.voice != null) { AudioManager.Instance.StopVoice(this.voice); } DialogueUI.CompleteLine(this); DialogueUI.HideText(); yield break; }
// OVERRIDE METHODS: ---------------------------------------------------------------------- protected override IEnumerator RunItem() { if (this.conditionsList != null && !this.conditionsList.Check()) { yield break; } if (this.children.Count <= 0) { yield break; } if (!string.IsNullOrEmpty(this.GetContent())) { yield return(this.RunShowText()); } this.hasMadeChoice = false; this.choiceIndex = -1; this.startTime = Time.time; DatabaseDialogue.ConfigData configData = this.GetConfigData(); this.hasChoicesAvailable = DialogueUI.StartChoices(this, configData); WaitUntil waitUntil = new WaitUntil(() => { if (!this.hasChoicesAvailable) { return(true); } if (this.timedChoice && Time.time > this.startTime + this.timeout.GetValue(gameObject)) { return(true); } return(this.hasMadeChoice); }); yield return(waitUntil); if (this.voice != null) { AudioManager.Instance.StopVoice(this.voice); } DialogueUI.CompleteLine(this); DialogueUI.HideText(); DialogueUI.HideChoices(); }
protected override IEnumerator RunItem() { this.continueSubitems = true; if (this.conditionsList != null && !this.conditionsList.Check()) { this.continueSubitems = false; yield break; } yield return(this.RunShowText()); if (this.voice != null) { AudioManager.Instance.StopVoice(this.voice); } DialogueUI.HideText(); yield break; }