From 8d47b4e4ba352a28b81af961c3314562b76b0ad6 Mon Sep 17 00:00:00 2001
From: client_Hale <339726288@qq.com>
Date: 星期一, 29 四月 2019 16:52:03 +0800
Subject: [PATCH] Merge branch 'master' of http://192.168.0.87:10010/r/snxxz_scripts
---
System/Skill/ExpertSkillSelectWin.cs | 26 ++++++++++++++++++++++----
1 files changed, 22 insertions(+), 4 deletions(-)
diff --git a/System/Skill/ExpertSkillSelectWin.cs b/System/Skill/ExpertSkillSelectWin.cs
index 032203a..2ecb1dc 100644
--- a/System/Skill/ExpertSkillSelectWin.cs
+++ b/System/Skill/ExpertSkillSelectWin.cs
@@ -108,7 +108,7 @@
for (int i = 0; i < m_SkillExperts.Length; i++)
{
var potential = skill.potentials[i];
- m_SkillExperts[i].Display(potential.id, OnSelect);
+ m_SkillExperts[i].Display(potential.id, skill.level >= potential.limitLevel, OnSelect);
}
}
}
@@ -125,12 +125,17 @@
{
if (selectExpert != 0)
{
+ TreasureSkill skill;
+ model.TryGetSkill(selectSkillId, out skill);
+
var level = 0;
TreasurePotential expert;
if (model.TryGetPotential(selectExpert, out expert))
{
level = expert.level;
}
+
+ m_Select.gameObject.SetActive(skill.level >= expert.limitLevel);
SkillConfig skillConfig;
if (level == 0)
@@ -193,18 +198,21 @@
[Serializable]
public class SkillExpertWidget
{
- [SerializeField] Image m_Icon;
+ [SerializeField] ImageEx m_Bottom;
+ [SerializeField] ImageEx m_Icon;
[SerializeField] Text m_SkillName;
+ [SerializeField] ImageEx m_ReikiBottom;
[SerializeField] Text m_Reiki;
[SerializeField] Transform m_ContainerSelect;
[SerializeField] Text m_Use;
+ [SerializeField] Text m_Limit;
[SerializeField] Button m_Select;
public int skillId { get; private set; }
TreasureSkillModel model { get { return ModelCenter.Instance.GetModel<TreasureSkillModel>(); } }
- public void Display(int skillId, Action<int> func)
+ public void Display(int skillId, bool unlock, Action<int> func)
{
this.skillId = skillId;
@@ -216,12 +224,22 @@
var property = skillConfig.RequireProperty();
var propertyConfig = PlayerPropertyConfig.Get(property);
m_Reiki.text = propertyConfig.Name;
- m_Reiki.color = UIHelper.GetPropertyColor(property);
+ m_Reiki.color = unlock ? UIHelper.GetPropertyColor(property) : UIHelper.s_Gray;
var selectExpertSkill = 0;
model.TryGetExpertSkill(ExpertSkillSelectWin.selectSkillId, out selectExpertSkill);
m_Use.gameObject.SetActive(selectExpertSkill == skillId);
+ TreasurePotential expert;
+ model.TryGetPotential(skillId, out expert);
+
+ m_Limit.text = string.Format("{0}绾у彲浣跨敤", expert.limitLevel);
+
+ m_Limit.gameObject.SetActive(!unlock);
+ m_Bottom.gray = !unlock;
+ m_Icon.gray = !unlock;
+ m_ReikiBottom.gray = !unlock;
+
m_Select.SetListener(() =>
{
if (func != null)
--
Gitblit v1.8.0