Browse Source

Merge remote-tracking branch 'remotes/origin/master' into xiaojie

hexiaojie 2 years ago
parent
commit
14b71d737c

+ 3 - 0
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/League/UI_ListSkillItem.cs

@@ -10,6 +10,7 @@ namespace UI.League
         public Controller m_c1;
         public Controller m_c1;
         public GLoader m_loaIcon;
         public GLoader m_loaIcon;
         public GImage m_imgLock;
         public GImage m_imgLock;
+        public GGraph m_holdeLight;
         public GLoader m_loaScore;
         public GLoader m_loaScore;
         public GTextField m_txtScore;
         public GTextField m_txtScore;
         public GImage m_imgSuo;
         public GImage m_imgSuo;
@@ -64,6 +65,7 @@ namespace UI.League
             m_c1 = comp.GetController("c1");
             m_c1 = comp.GetController("c1");
             m_loaIcon = (GLoader)comp.GetChild("loaIcon");
             m_loaIcon = (GLoader)comp.GetChild("loaIcon");
             m_imgLock = (GImage)comp.GetChild("imgLock");
             m_imgLock = (GImage)comp.GetChild("imgLock");
+            m_holdeLight = (GGraph)comp.GetChild("holdeLight");
             m_loaScore = (GLoader)comp.GetChild("loaScore");
             m_loaScore = (GLoader)comp.GetChild("loaScore");
             m_txtScore = (GTextField)comp.GetChild("txtScore");
             m_txtScore = (GTextField)comp.GetChild("txtScore");
             m_imgSuo = (GImage)comp.GetChild("imgSuo");
             m_imgSuo = (GImage)comp.GetChild("imgSuo");
@@ -74,6 +76,7 @@ namespace UI.League
             m_c1 = null;
             m_c1 = null;
             m_loaIcon = null;
             m_loaIcon = null;
             m_imgLock = null;
             m_imgLock = null;
+            m_holdeLight = null;
             m_loaScore = null;
             m_loaScore = null;
             m_txtScore = null;
             m_txtScore = null;
             m_imgSuo = null;
             m_imgSuo = null;

+ 18 - 26
GameClient/Assets/Game/HotUpdate/Views/League/LeagueSkillUpView.cs

@@ -17,9 +17,8 @@ namespace GFGGame
         private EffectUI _effectUI2;
         private EffectUI _effectUI2;
         private EffectUI _effectUI3;
         private EffectUI _effectUI3;
         private List<EffectUI> _effectUIs = new List<EffectUI>();
         private List<EffectUI> _effectUIs = new List<EffectUI>();
-        private List<GComponent> _items = new List<GComponent>();
-        private int _pageCount;
         private int _type;
         private int _type;
+        private int saveListPageIndex = 0;
 
 
         public override void Dispose()
         public override void Dispose()
         {
         {
@@ -67,7 +66,7 @@ namespace GFGGame
 
 
             _ui.m_loaBg.url = ResPathUtil.GetBgImgPath("lm_ch_jnbg");
             _ui.m_loaBg.url = ResPathUtil.GetBgImgPath("lm_ch_jnbg");
 
 
-            _effectUI1 = EffectUIPool.CreateEffectUI(_ui.m_holder, "ui_league", "TEA");
+            _effectUI1 = EffectUIPool.CreateEffectUI(_ui.m_holder, "ui_league", "TEA",110);
             _effectUI2 = EffectUIPool.CreateEffectUI(_ui.m_holderSkill, "ui_league", "tea_unlock");
             _effectUI2 = EffectUIPool.CreateEffectUI(_ui.m_holderSkill, "ui_league", "tea_unlock");
             _effectUI3 = EffectUIPool.CreateEffectUI(_ui.m_holderScore, "ui_league", "tea_unlock");
             _effectUI3 = EffectUIPool.CreateEffectUI(_ui.m_holderScore, "ui_league", "tea_unlock");
         }
         }
@@ -108,11 +107,9 @@ namespace GFGGame
             for (int i = 0; i < _effectUIs.Count; i++)
             for (int i = 0; i < _effectUIs.Count; i++)
             {
             {
                 EffectUIPool.Recycle(_effectUIs[i]);
                 EffectUIPool.Recycle(_effectUIs[i]);
-                _items[i].RemoveChildAt(4);
+                _effectUIs[i] = null;
             }
             }
-
             _effectUIs.Clear();
             _effectUIs.Clear();
-            _items.Clear();
         }
         }
 
 
         protected override void RemoveEventListener()
         protected override void RemoveEventListener()
@@ -132,7 +129,9 @@ namespace GFGGame
             int curPage = index / _ui.m_comSkill.m_list.lineCount;
             int curPage = index / _ui.m_comSkill.m_list.lineCount;
             int nextPage = curPage + 1;
             int nextPage = curPage + 1;
             if (nextPage * _ui.m_comSkill.m_list.lineCount > _ui.m_comSkill.m_list.numItems - 1) return;
             if (nextPage * _ui.m_comSkill.m_list.lineCount > _ui.m_comSkill.m_list.numItems - 1) return;
-            _ui.m_comSkill.m_list.ScrollToView(nextPage * _ui.m_comSkill.m_list.lineCount, true);
+            DestroySkillAni();
+            saveListPageIndex = nextPage * _ui.m_comSkill.m_list.lineCount;
+            _ui.m_comSkill.m_list.ScrollToView(saveListPageIndex, true);
             Debug.Log("curPage:" + nextPage);
             Debug.Log("curPage:" + nextPage);
         }
         }
 
 
@@ -142,7 +141,9 @@ namespace GFGGame
             int curPage = index / _ui.m_comSkill.m_list.lineCount;
             int curPage = index / _ui.m_comSkill.m_list.lineCount;
             int lastPage = curPage - 1;
             int lastPage = curPage - 1;
             if (lastPage * _ui.m_comSkill.m_list.lineCount < 0) return;
             if (lastPage * _ui.m_comSkill.m_list.lineCount < 0) return;
-            _ui.m_comSkill.m_list.ScrollToView(lastPage * _ui.m_comSkill.m_list.lineCount, true);
+            DestroySkillAni();
+            saveListPageIndex = lastPage * _ui.m_comSkill.m_list.lineCount;
+            _ui.m_comSkill.m_list.ScrollToView(saveListPageIndex, true);
             Debug.Log("curPage:" + lastPage);
             Debug.Log("curPage:" + lastPage);
         }
         }
 
 
@@ -230,12 +231,13 @@ namespace GFGGame
             item.m_loaIcon.url = string.Format("ui://League/tb_jn_{0}", _type);
             item.m_loaIcon.url = string.Format("ui://League/tb_jn_{0}", _type);
             bool isLock = !SkillDataManager.Instance.LeagueSkillDatas.ContainsKey(_type) ||
             bool isLock = !SkillDataManager.Instance.LeagueSkillDatas.ContainsKey(_type) ||
                           SkillDataManager.Instance.LeagueSkillDatas[_type].IndexOf(skillCfgs[index].id) < 0;
                           SkillDataManager.Instance.LeagueSkillDatas[_type].IndexOf(skillCfgs[index].id) < 0;
-          
+
             item.m_imgLock.visible = isLock;
             item.m_imgLock.visible = isLock;
 
 
             bool canActive = true;
             bool canActive = true;
             List<LeagueSkillCfg> lastSkillCfgs =
             List<LeagueSkillCfg> lastSkillCfgs =
-                LeagueSkillCfgArray.Instance.GetCfgsBytypeAndlayer(_type, skillCfgs[index].layer - 1);
+                 LeagueSkillCfgArray.Instance.GetCfgsBytypeAndlayer(_type, skillCfgs[index].layer - 1);
+
             for (int i = 0; i < lastSkillCfgs.Count; i++)
             for (int i = 0; i < lastSkillCfgs.Count; i++)
             {
             {
                 if (!SkillDataManager.Instance.LeagueSkillDatas.ContainsKey(_type) ||
                 if (!SkillDataManager.Instance.LeagueSkillDatas.ContainsKey(_type) ||
@@ -246,28 +248,18 @@ namespace GFGGame
                 }
                 }
             }
             }
 
 
-            if (!canActive)
-                item.m_c1.selectedIndex = 0;
-            else
-                item.m_c1.selectedIndex = 1;
+            item.m_imgSuo.visible = !canActive;
 
 
             if (isLock && canActive && _effectUIs.Count <= index)
             if (isLock && canActive && _effectUIs.Count <= index)
             {
             {
-                GGraph holder = new GGraph();
-                holder.SetSize(1, 1);
-                holder.SetPosition(80, 80, 0);
-                holder.name = "holder";
-                item.target.AddChildAt(holder, 4);
-                EffectUI _effectUI = EffectUIPool.CreateEffectUI(holder, "ui_league", "tea_nolearn");
+                EffectUI _effectUI = EffectUIPool.CreateEffectUI(item.m_holdeLight, "ui_league", "tea_nolearn");
                 _effectUIs.Add(_effectUI);
                 _effectUIs.Add(_effectUI);
-                _items.Add(item.target);
             }
             }
 
 
-            GObject gObject = item.target.GetChild("holder");
-            if (gObject != null)
-            {
-                gObject.visible = isLock && canActive;
-            }
+            if (isLock && canActive) 
+                item.m_c1.selectedIndex = 1;
+            else
+                item.m_c1.selectedIndex = 0;
 
 
             ItemUtil.UpdateItemNeedNum(item.m_comCost, skillCfgs[index].consumeArr[0], false, "#FFFBF4");
             ItemUtil.UpdateItemNeedNum(item.m_comCost, skillCfgs[index].consumeArr[0], false, "#FFFBF4");
             if (item.target.data == null)
             if (item.target.data == null)

BIN
GameClient/Assets/ResIn/UI/CommonGame/CommonGame_fui.bytes


BIN
GameClient/Assets/ResIn/UI/League/League_atlas0.png


BIN
GameClient/Assets/ResIn/UI/League/League_atlas0_1!a.png


BIN
GameClient/Assets/ResIn/UI/League/League_atlas0_1.png


BIN
GameClient/Assets/ResIn/UI/League/League_atlas0_3!a.png


BIN
GameClient/Assets/ResIn/UI/League/League_atlas0_3.png


BIN
GameClient/Assets/ResIn/UI/League/League_atlas0_4!a.png


BIN
GameClient/Assets/ResIn/UI/League/League_atlas0_4.png


BIN
GameClient/Assets/ResIn/UI/League/League_atlas0_5!a.png


BIN
GameClient/Assets/ResIn/UI/League/League_atlas0_5.png


BIN
GameClient/Assets/ResIn/UI/League/League_atlas0_6!a.png


BIN
GameClient/Assets/ResIn/UI/League/League_atlas0_6.png


BIN
GameClient/Assets/ResIn/UI/League/League_atlas0_7!a.png


BIN
GameClient/Assets/ResIn/UI/League/League_atlas0_7.png


BIN
GameClient/Assets/ResIn/UI/League/League_fui.bytes