From 9be1915c2b8449b6b343a05733472b015eed1c4b Mon Sep 17 00:00:00 2001
From: client_linchunjie <461730578@qq.com>
Date: 星期三, 08 五月 2019 11:16:44 +0800
Subject: [PATCH] 6680 子 【2.0】【开发】五行专精激活方式变更 / 【2.0】【前端】五行专精激活方式变更
---
System/Skill/ExpertSkillSelectWin.cs | 31 +++++++++++++++++++++++++++----
1 files changed, 27 insertions(+), 4 deletions(-)
diff --git a/System/Skill/ExpertSkillSelectWin.cs b/System/Skill/ExpertSkillSelectWin.cs
index 68e65f0..910c242 100644
--- a/System/Skill/ExpertSkillSelectWin.cs
+++ b/System/Skill/ExpertSkillSelectWin.cs
@@ -137,7 +137,7 @@
}
}
- void DisplayDetail()
+ void DisplayDetail(bool animationStep = false)
{
if (selectExpert != 0)
{
@@ -168,19 +168,42 @@
}
}
- //m_LayoutElement.preferredHeight = datas.Count > 2 ? 440 : 302;
+ if (!animationStep)
+ {
+ m_LayoutElement.preferredHeight = datas.Count > 2 ? 440 : 302;
+ }
m_CyclicScroll.enabled = true;
m_CyclicScroll.Dispose();
m_CyclicScroll.Init(datas);
- StartCoroutine(Co_Arrange());
+ StartCoroutine(Co_Arrange(animationStep));
}
}
- IEnumerator Co_Arrange()
+ IEnumerator Co_Arrange(bool animationStep)
{
yield return null;
+ if (animationStep)
+ {
+ var start = m_LayoutElement.preferredHeight;
+ var intValue = (int)start;
+ if (start > 302)
+ {
+ while (start > 302)
+ {
+ start -= Time.deltaTime * 10;
+ start = Mathf.Max(302, start);
+ m_LayoutElement.preferredHeight = start;
+ if (intValue != (int)start)
+ {
+ intValue = (int)start;
+ m_CyclicScroll.ReArrange();
+ }
+ }
+ yield break;
+ }
+ }
m_CyclicScroll.ReArrange();
}
--
Gitblit v1.8.0