diff --git a/Assets/ManagedResources/~Lua/Modules/CompoundHero/view/CompoundHero_Replace.lua b/Assets/ManagedResources/~Lua/Modules/CompoundHero/view/CompoundHero_Replace.lua
index 200a99e18c..6d7c224f07 100644
--- a/Assets/ManagedResources/~Lua/Modules/CompoundHero/view/CompoundHero_Replace.lua
+++ b/Assets/ManagedResources/~Lua/Modules/CompoundHero/view/CompoundHero_Replace.lua
@@ -7,6 +7,9 @@ local curSelectHero = {}
local curSelectHeroConfig = {}
local heroSelectBtn = {}
local heroDatas
+local t
+local replaceItemIdConfig = ConfigManager.GetConfigData(ConfigName.SpecialConfig,68)
+local replaceCostConfig = ConfigManager.GetConfigData(ConfigName.SpecialConfig,69)
local HeroConfig = ConfigManager.GetConfig(ConfigName.HeroConfig)
@@ -45,7 +48,12 @@ end
function this:BindEvent()
--置换
Util.AddClick(this.replaceBtn,function()
- if not not curSelectHero.id then
+
+ if not curSelectHero.id then
+ PopupTipPanel.ShowTip("请选择想要置换的神将!")
+ elseif curSelectHero.id and (t>BagManager.GetTotalItemNum(tonumber(replaceItemIdConfig.Value))) then
+ PopupTipPanel.ShowTip("置换玉不足!")
+ else
NetManager.SaveHeroChangeRequest(curSelectHero.dynamicId,function (msg)
HeroManager.ResetHeroChangeId(curSelectHero.dynamicId,msg.heroTempId)--改变英雄changeId
@@ -63,8 +71,6 @@ function this:BindEvent()
local value = this.RebuildData(msg.heroTempId,curSelectHero)
this.SetHero(this.replaceHero,value)
end)
- else
- PopupTipPanel.ShowTip("请选择想要置换的神将!")
end
end)
--取消
@@ -403,14 +409,11 @@ function this.SetBtnSelect(_parObj)
end
function this.ShowCostInfo()
- local replaceItemIdConfig = ConfigManager.GetConfigData(ConfigName.SpecialConfig,68)
- local replaceCostConfig = ConfigManager.GetConfigData(ConfigName.SpecialConfig,69)
if replaceItemIdConfig then
this.costImage:GetComponent("Image").sprite = SetIcon(tonumber(replaceItemIdConfig.Value))
end
if curSelectHero and replaceCostConfig then
- local t
local getCostByStar = string.split(replaceCostConfig.Value,"|")
if curSelectHero.star == 4 then
t = tonumber(string.split(getCostByStar[1],"#")[2])
diff --git a/Assets/ManagedResources/~Lua/Modules/Popup/View/GeneralPopup_HeavenUnlockExtraRewardPanel.lua b/Assets/ManagedResources/~Lua/Modules/Popup/View/GeneralPopup_HeavenUnlockExtraRewardPanel.lua
index 62bebf260a..ef8e920d8c 100644
--- a/Assets/ManagedResources/~Lua/Modules/Popup/View/GeneralPopup_HeavenUnlockExtraRewardPanel.lua
+++ b/Assets/ManagedResources/~Lua/Modules/Popup/View/GeneralPopup_HeavenUnlockExtraRewardPanel.lua
@@ -57,7 +57,7 @@ function this:OnShow(_parent,...)
rewardStateData = TreasureOfHeavenManger.GetState()
rewardData = TreasureOfHeavenManger.GetAllRewardData()
this:showRewardTianGong()
- this.tip.text = "解锁高阶战令,激活进阶专属奖励"
+ this.tip.text = "解锁秘宝,可以领取额外专属奖励,并直接获得200积分"
elseif curType == 2 then
rewardData = QinglongSerectTreasureManager.GetAllRewardData()
this:showRewardQinglong()