bug修复

This commit is contained in:
xiekaidong 2023-07-25 17:16:54 +08:00
parent 53d7e103ec
commit 03c6bdd523
2 changed files with 4 additions and 3 deletions

View File

@ -159,8 +159,9 @@ function ArmorInfoComp:refreshSelectArmor()
end
self.txNum:setText(armorEntity:getUpgradeGoldNum())
self.btnUp:setTouchEnable(self.heroEntity:isActived())
local canLvUp = armorEntity:canLevelUp()
if canLvUp then
if self.heroEntity:isActived() and canLvUp then
self.btnUp:addRedPoint(120, 50, 0.6)
self.btnUp:setSprite(GConst.ATLAS_PATH.COMMON, BTN_ICON[1])
else

View File

@ -122,9 +122,9 @@ function WeaponInfoComp:refresh()
self.txNum:setText("<color=#FF5252>" .. self.weaponEntity:getUpgradeGoldNum() .. "</color>")
end
self.btnUp:setTouchEnable(self.heroEntity:isUnlock())
self.btnUp:setTouchEnable(self.heroEntity:isActived())
local canLvUp = self.weaponEntity:canLevelUp()
if self.heroEntity:isUnlock() and canLvUp then
if self.heroEntity:isActived() and canLvUp then
self.btnUp:addRedPoint(120, 50, 0.6)
self.btnUp:setSprite(GConst.ATLAS_PATH.COMMON, BTN_ICON[1])
else