This commit is contained in:
puxuan 2025-09-03 20:42:20 +08:00
parent 3e91ceadfc
commit ec86c17b8d

View File

@ -42,9 +42,9 @@ end
function BattleUIPVP:initBg() function BattleUIPVP:initBg()
self.bg = self.uiMap["battle_ui_pvp.battle_root.bg"] self.bg = self.uiMap["battle_ui_pvp.battle_root.bg"]
self.bg:setLocalScale(0, 0, 0) -- self.bg:setLocalScale(0, 0, 0)
local width = self.bg:fastGetSizeDelta() -- local width = self.bg:fastGetSizeDelta()
self.bg:setAnchoredPositionX(width/4) -- self.bg:setAnchoredPositionX(width/4)
end end
function BattleUIPVP:initSkill() function BattleUIPVP:initSkill()
@ -202,6 +202,10 @@ function BattleUIPVP:refreshAvatar()
self.defPlayerHeadCell:refresh(defInfo.avatar, defInfo.avatar_frame) self.defPlayerHeadCell:refresh(defInfo.avatar, defInfo.avatar_frame)
end end
function BattleUIPVP:loadBg(bgName)
self.bg:setLocalScale(1, 1, 1)
end
function BattleUIPVP:showLeftBuffTips(buffList, autoClose) function BattleUIPVP:showLeftBuffTips(buffList, autoClose)
local addY = self:showBuffTips(buffList, autoClose) local addY = self:showBuffTips(buffList, autoClose)
self.battleBuffTipsBg:setAnchoredPosition(-175, -1050 + addY) self.battleBuffTipsBg:setAnchoredPosition(-175, -1050 + addY)