From 736293cbe9a697058edc0e24ea751c94c947b2ea Mon Sep 17 00:00:00 2001 From: jiaoyangna <3046463818@qq.com> Date: Wed, 26 May 2021 20:53:18 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A4=B4=E5=83=8F=E6=A1=86=E9=A2=9C=E8=89=B2?= =?UTF-8?q?=E6=8F=90=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../~Lua/Modules/Map/View/EndLessMapView.lua | 26 +++++++++---------- .../~Lua/Modules/Net/NetManager.lua | 3 --- .../Popup/View/GeneralPopup_Onhook.lua | 2 +- 3 files changed, 14 insertions(+), 17 deletions(-) diff --git a/Assets/ManagedResources/~Lua/Modules/Map/View/EndLessMapView.lua b/Assets/ManagedResources/~Lua/Modules/Map/View/EndLessMapView.lua index 48705e61d7..8e32502309 100644 --- a/Assets/ManagedResources/~Lua/Modules/Map/View/EndLessMapView.lua +++ b/Assets/ManagedResources/~Lua/Modules/Map/View/EndLessMapView.lua @@ -313,7 +313,7 @@ function EndLessMapView:OnShow() -- 如果全屏界面打开时刷新过,重新激活界面需要刷新一次 if EndLessMapManager.isUpdateOnClose then - this:GetBagEnergy() + this.GetBagEnergy() EndLessMapManager.isUpdateOnClose = false end @@ -340,7 +340,6 @@ function EndLessMapView:ShowHeroData() if not this.heroList then this.heroList = {} end - LogGreen("#this.heroList:"..#this.heroList) for k = 1, #this.heroList do if this.heroList[k] and this.heroList[k].go then this.heroList[k].go.gameObject:SetActive(false) @@ -368,7 +367,7 @@ function EndLessMapView:ShowHeroData() this.heroList[i].go.gameObject:SetActive(true) this.heroList[i].heroId = v.heroId local heroData = HeroManager.GetSingleHeroData(v.heroId) - this.heroList[i].frame.sprite=Util.LoadSprite(GetHeroQuantityImageByquality(heroData.heroConfig.Quality, v.star)) + this.heroList[i].frame.sprite=Util.LoadSprite(GetHeroQuantityImageByquality(heroData.heroConfig.Quality, heroData.star)) SetHeroIcon(this.spLoader,heroData,this.heroList[i].icon,heroData.heroConfig) this.heroList[i].pro.sprite=Util.LoadSprite(GetProStrImageByProNum(heroData.heroConfig.PropertyName)) this.heroList[i].lv.text=heroData.lv @@ -403,6 +402,7 @@ function EndLessMapView:SetShiQiValue() local itemCount = BagManager.GetItemCountById(EndLessMapManager.shiQiValue) local id, lv = EndLessMapManager.GetShiQiValue() local oldId = 0 + LogGreen("lv:"..lv.." EndLessMapManager.moraleLv:"..EndLessMapManager.moraleLv) if lv ~= EndLessMapManager.moraleLv then isShow = true oldId = EndLessMapManager.moraleLv @@ -414,11 +414,11 @@ function EndLessMapView:SetShiQiValue() this.shiQiLv.text = lv.."级" this.shiQifillAmount.fillAmount = (endlessMorale[id].Exp and endlessMorale[id].Exp[2] > 0) and itemCount/endlessMorale[id].Exp[2] or 1 + LogGreen("isShow:"..tostring(isShow)) if isShow then --士气等级提升 isShow = false local data = {} - LogGreen("isShow:"..tostring(isShow) ) data.title = "r_wujin_shiqitishengzi" --士气等级提升图片 data.itemList = {} data.type = 2 @@ -427,11 +427,13 @@ function EndLessMapView:SetShiQiValue() local proPs = {} for k,v in ConfigPairs(endlessMorale) do if v.Id <= curId then - for i = 1 ,#v.Props do - if not proPs[v.Props[i][1]] then - proPs[v.Props[i][1]] = 0 + if v.Props then + for i = 1 ,#v.Props do + if not proPs[v.Props[i][1]] then + proPs[v.Props[i][1]] = 0 + end + proPs[v.Props[i][1]] = proPs[v.Props[i][1]] + v.Props[i][2] end - proPs[v.Props[i][1]] = proPs[v.Props[i][1]] + v.Props[i][2] end end end @@ -455,7 +457,7 @@ function EndLessMapView:SetShiQiValue() table.insert(data.itemList,singleItem) end if cursinglePro.Skill and cursinglePro.Skill > 0 then - local config = ConfigManager.GetConfigData(ConfigName.SkillConfig,cursinglePro.Skill) + local config = ConfigManager.GetConfigData(ConfigName.PassiveSkillConfig,cursinglePro.Skill) local singleItem = {} singleItem.icon = nil singleItem.proName = config.Desc @@ -554,7 +556,7 @@ function EndLessMapView:InitCostValue() deadCost = mapData.DeathCost -- 同步一次道具数据 - this:GetBagEnergy() + this.GetBagEnergy() -- 显示你有多少钱钱 this.moneyNum:GetComponent("Text").text = BagManager.GetTotalItemNum(1201) @@ -629,7 +631,7 @@ function EndLessMapView:RefreshEnergyShow() end -- 刷新数值 -function EndLessMapView:GetBagEnergy() +function this.GetBagEnergy() -- 无尽副本才刷新 if not this:IsEndLessMap() then return end EndLessMapManager.leftEnergy = BagManager.GetItemCountById(1) @@ -642,8 +644,6 @@ function EndLessMapView:GetBagEnergy() this.moneyIcon:GetComponent("Image").sprite = SetIcon(this.spLoader, 1201) this:SetShiQiValue() - - end -- 无尽副本中角色死翘翘 diff --git a/Assets/ManagedResources/~Lua/Modules/Net/NetManager.lua b/Assets/ManagedResources/~Lua/Modules/Net/NetManager.lua index 80dbbfe042..605c2fde3b 100644 --- a/Assets/ManagedResources/~Lua/Modules/Net/NetManager.lua +++ b/Assets/ManagedResources/~Lua/Modules/Net/NetManager.lua @@ -2229,9 +2229,6 @@ function this.RequestAllHeroHp(func) local data = buffer:DataByte() local msg = MapInfoProto_pb.GetEndlessHeroResponse() msg:ParseFromString(data) - for i = 1,#msg.heroInfo do - LogGreen(msg.heroInfo[i].heroId) - end EndLessMapManager.InitHeroHp(msg, function() if func then func() diff --git a/Assets/ManagedResources/~Lua/Modules/Popup/View/GeneralPopup_Onhook.lua b/Assets/ManagedResources/~Lua/Modules/Popup/View/GeneralPopup_Onhook.lua index b42998623b..6e1b1b3397 100644 --- a/Assets/ManagedResources/~Lua/Modules/Popup/View/GeneralPopup_Onhook.lua +++ b/Assets/ManagedResources/~Lua/Modules/Popup/View/GeneralPopup_Onhook.lua @@ -90,7 +90,7 @@ function this:OnShow(_parent,...) end this.timer = Timer.New(function() parent:ClosePanel() - end,2):Start() + end,5):Start() end function this:OnClose()