public void Play() { if (!IsPlaying()) { isStopped = false; isPaused = false; if (timer != null && !timer.IsPaused) { timer.Execute(); } } }
private void ExecuteSubtitles() { currentNode.Execute(); timer = new _Timer(0.1f, 0.1f, DialogManager.Instance); timer.OnUpdate += delegate { if (timer.ElapsedTimeF >= currentNode.dialogPartStartDuration) { currentNode.nodeCompleted = true; DialogManager.Instance.SubtitleArea.text = ""; if (currentNode.transitions.Count > 0) { DecideForNextNode(); } timer.Stop(); } }; timer.Execute(); }