少年修仙传客户端代码仓库
client_Zxw
2018-10-10 ed1bfe3baec948db5e23270f3507036ad2f854b3
3870 【前端】角色升级表现修改
1个文件已修改
16 ■■■■ 已修改文件
System/MainInterfacePanel/UpgradeWin.cs 16 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/MainInterfacePanel/UpgradeWin.cs
@@ -18,6 +18,7 @@
        [SerializeField] UIAlphaTween m_UIAlphaTween;
        [SerializeField] Text m_TextLV;
        [SerializeField] UIEffect m_UIEffect;
        public float Delay = 0.5f;
        #region Built-in
        protected override void BindController()
        {
@@ -35,8 +36,12 @@
        protected override void OnActived()
        {
            m_UIEffect.Play();
            m_UIEffect.OnComplete = () => { Close(); };
            m_ScaleTween.Play(false,()=> { m_UIAlphaTween.Play(); });
            m_UIEffect.OnComplete = () =>
            {
                StopCoroutine(DelayIEnumerator());
                Close();
            };
            m_ScaleTween.Play(false, () => { StartCoroutine(DelayIEnumerator()); });
        }
        protected override void OnAfterOpen()
        {
@@ -56,11 +61,18 @@
        protected override void OnAfterClose()
        {
        }
        IEnumerator DelayIEnumerator()
        {
            yield return new WaitForSeconds(Delay);
            m_UIAlphaTween.Play();
        }
        #endregion
        private void windowBeforeClose(Window _window)
        {
            if (_window is MainInterfaceWin)
            {
                StopCoroutine(DelayIEnumerator());
                Close();
            }
        }