diff --git a/Assets/ManagedResources/~Lua/Modules/Guild/Skill/GuildSkillUpLvPopup.lua b/Assets/ManagedResources/~Lua/Modules/Guild/Skill/GuildSkillUpLvPopup.lua index fc9c223b06..3bfd976157 100644 --- a/Assets/ManagedResources/~Lua/Modules/Guild/Skill/GuildSkillUpLvPopup.lua +++ b/Assets/ManagedResources/~Lua/Modules/Guild/Skill/GuildSkillUpLvPopup.lua @@ -65,11 +65,10 @@ function GuildSkillUpLvPopup:BindEvent() return end NetManager.SinGleGuildSkillUpLv(curIndex,function(msg) - CheckRedPointStatus(RedPointType.Guild_Skill) PopupTipPanel.ShowTip(Language[11086]) GuildSkillManager.SetSkillDataLv(curIndex,curSeletSkill.id,curSeletSkill.level + 1) - this.OnClickTabBtn(curIndex) - this.RefreshTabRedPoint() + this.OnClickTabBtn(curIndex,true) + this.RefreshTabRedPoint(curIndex) newWarPowerValue = FormationManager.GetFormationPower(FormationTypeDef.FORMATION_NORMAL) if oldWarPowerValue ~= newWarPowerValue then UIManager.OpenPanel(UIName.WarPowerChangeNotifyPanelV2,{oldValue = oldWarPowerValue,newValue = newWarPowerValue}) @@ -77,6 +76,7 @@ function GuildSkillUpLvPopup:BindEvent() oldWarPowerValue = newWarPowerValue end Game.GlobalEvent:DispatchEvent(GameEvent.Player.OnChangeName) + -- CheckRedPointStatus(RedPointType.Guild_Skill) end) end) Util.AddClick(this.btnRest,function() @@ -86,9 +86,9 @@ function GuildSkillUpLvPopup:BindEvent() end UIManager.OpenPanel(UIName.GeneralPopup,GENERAL_POPUP_TYPE.GuildSkill, GuildSkillManager.GetResetGetDrop(curIndex),curIndex,function() - CheckRedPointStatus(RedPointType.Guild_Skill) + -- CheckRedPointStatus(RedPointType.Guild_Skill) GuildSkillManager.ResetGuildSkillData(curIndex) - this.OnClickTabBtn(curIndex) + this.OnClickTabBtn(curIndex,true) this.RefreshTabRedPoint() Game.GlobalEvent:DispatchEvent(GameEvent.Player.OnChangeName) end) @@ -131,7 +131,7 @@ end function this.SwitchView(index) this.OnClickTabBtn(index) end -function this.OnClickTabBtn(index) +function this.OnClickTabBtn(index,isNoLoadSprite) --数据组拼 curIndex = index GuildSkillManager.SetGuildSkillRedPlayers(curIndex,1) @@ -149,11 +149,11 @@ function this.OnClickTabBtn(index) if isMaxLv and curSeletSkill.level ~= #allCurSkillConfig - 1 then isMaxLv = false end - this.ShowSkillsAndPros()--展示技能 展示属性 + this.ShowSkillsAndPros(isNoLoadSprite)--展示技能 展示属性 this.ShowMaterials()--展示消耗材料 及 按钮状态 end --展示技能 -function this.ShowSkillsAndPros() +function this.ShowSkillsAndPros(isNoLoadSprite) this.titleText.text = Language[11088].._TabData[curIndex].name local isEqualityLv,maxLv endLv,isEqualityLv,maxLv = GuildSkillManager.GetAllGuildSkillLv(curIndex) @@ -171,7 +171,9 @@ function this.ShowSkillsAndPros() for i = 1, #allSkillData do local skillGo = skills[i] if skillGo then - Util.GetGameObject(skillGo,"icon"):GetComponent("Image").sprite = Util.LoadSprite(GetResourcePath(allSkillData[i].config.Icon)) + if not isNoLoadSprite then + Util.GetGameObject(skillGo,"icon"):GetComponent("Image").sprite = Util.LoadSprite(GetResourcePath(allSkillData[i].config.Icon)) + end Util.GetGameObject(skillGo,"lvImage/Text"):GetComponent("Text").text = allSkillData[i].level if isEqualityLv then Util.SetGray(skillGo, true) @@ -234,10 +236,14 @@ function this.ShowMaterials() end end end -function this.RefreshTabRedPoint() +function this.RefreshTabRedPoint(index) + if index then + tabRedPotList[index]:SetActive(false) + else for i = 1, #tabRedPotList do tabRedPotList[i]:SetActive(GuildSkillManager.GuildSkillRedPoint(i)) end + end end --界面关闭时调用(用于子类重写) function GuildSkillUpLvPopup:OnClose()