节奏调整

This commit is contained in:
xiekaidong 2023-06-30 20:54:17 +08:00
parent 4aa36c0122
commit f672783ab5

View File

@ -231,8 +231,6 @@ function BattleUIPVP:enterShowBoardAni(callback)
self.boardNode:setVisible(true)
self.boardNode:setAnchoredPositionX(0)
self.enterShowBoardSeq = self.root:createBindTweenSequence()
if not self.root.tag then
self.root.tag = true
self.enterShowBoardSeq:AppendCallback(function()
for posId, entity in pairs(self.battleController.battleData:getGridEnties()) do
if entity:getCell() then
@ -249,7 +247,6 @@ function BattleUIPVP:enterShowBoardAni(callback)
end
end
end)
end
self.enterShowBoardSeq:Join(self.defBoardImg:getTransform():DOAnchorPosX(0, 0.5))
self.enterShowBoardSeq:Join(self.atkBoardImg:getTransform():DOAnchorPosX(0, 0.5))
@ -275,7 +272,10 @@ end
function BattleUIPVP:enterHideBoardAni(callback)
self:dealBoardMaskOnShowAni()
self:clearEnterShowBoardSeq()
self.enterShowBoardSeq = self.root:createBindTweenSequence()
self.enterShowBoardSeq:AppendInterval(0.5)
self.enterShowBoardSeq:AppendCallback(function()
local isAtkAction = self.battleController.curActionSide == GConst.BattleConst.SIDE_ATK
for posId, entity in pairs(self.battleController.battleData:getGridEnties()) do
if entity:getCell() then
@ -291,10 +291,7 @@ function BattleUIPVP:enterHideBoardAni(callback)
end
end
end
self:clearEnterShowBoardSeq()
self.enterShowBoardSeq = self.root:createBindTweenSequence()
self.enterShowBoardSeq:AppendInterval(1)
end)
local w, h = GFunc.getUIExpandScreenSize()
self.enterShowBoardSeq:Join(self.defBoardImg:getTransform():DOAnchorPosX(w + 360, 0.5))
self.enterShowBoardSeq:Join(self.atkBoardImg:getTransform():DOAnchorPosX(-(w + 360), 0.5))