From 33d5ce86967497eec9d31fa9ac372c1f632cc779 Mon Sep 17 00:00:00 2001 From: wangguan <wangguan@kt007.com> Date: Fri, 04 Dec 2020 18:05:15 +0800 Subject: [PATCH] 结束引导特效最后显示 新手获得精灵飞动特效 不显示PVP版本预告 --- Assets/Scripts/Guide/CharForeach.cs | 18 ++++++++++++++++++ 1 files changed, 18 insertions(+), 0 deletions(-) diff --git a/Assets/Scripts/Guide/CharForeach.cs b/Assets/Scripts/Guide/CharForeach.cs index 26738dc..0974cc9 100644 --- a/Assets/Scripts/Guide/CharForeach.cs +++ b/Assets/Scripts/Guide/CharForeach.cs @@ -12,6 +12,7 @@ private Text text; public delegate void CallBack(); private Action callBack; + private Action callBackFinal = null; void Awake() { @@ -39,6 +40,20 @@ word = wordArray[arrayIndex]; text.text = ""; callBack = cb; + StartCoroutine("TypeText"); + } + } + + public void StartFinalShowWord(string[] str, Action cb, Action cb2) + { + if (!isStarting) + { + wordArray = str; + arrayIndex = 0; + word = wordArray[arrayIndex]; + text.text = ""; + callBack = cb; + callBackFinal = cb2; StartCoroutine("TypeText"); } } @@ -80,6 +95,8 @@ { SetText(charArray[i]); } + callBackFinal?.Invoke(); + } } @@ -95,6 +112,7 @@ } isStarting = false; + callBackFinal?.Invoke(); yield break; } -- Gitblit v1.9.1