This commit is contained in:
xiekaidong 2023-04-23 14:19:44 +08:00
parent 73ad9f50f3
commit d8bf6274d8
2 changed files with 10 additions and 1 deletions

View File

@ -728,13 +728,21 @@ function BattleUI:eliminationAni(sequence, callback)
else else
self.eliminationAniSeq:Insert(index * 0.01, baseObject:getTransform():DOScale(1.3, 0.1)) self.eliminationAniSeq:Insert(index * 0.01, baseObject:getTransform():DOScale(1.3, 0.1))
self.eliminationAniSeq:Insert(index * 0.01 + 0.2, baseObject:getTransform():DOAnchorPos(self:getElementSkillPos(entity:getElementType()), 0.3)) self.eliminationAniSeq:Insert(index * 0.01 + 0.2, baseObject:getTransform():DOAnchorPos(self:getElementSkillPos(entity:getElementType()), 0.3))
self.eliminationAniSeq:Insert(index * 0.01 + 0.2, baseObject:getTransform():DOScale(1, 0.3)) self.eliminationAniSeq:Insert(index * 0.01 + 0.2, baseObject:getTransform():DOScale(0.5, 0.3))
end end
end end
end end
end end
self.eliminationAniSeq:AppendCallback(function() self.eliminationAniSeq:AppendCallback(function()
for posId, _ in pairs(self.posIdMap) do
local entity = DataManager.BattleData:getGridEntity(posId)
if entity and entity:getCell() then
entity:getCell():hideAni()
end
end
self.posIdMap = {} self.posIdMap = {}
if self.boardMask2D then if self.boardMask2D then
self.boardMask2D.enabled = true self.boardMask2D.enabled = true

View File

@ -133,6 +133,7 @@ end
function GridCell:resetTranform() function GridCell:resetTranform()
local uiMap = self:getUIMap() local uiMap = self:getUIMap()
self.baseObject:setLocalScale(1, 1, 1)
uiMap["grid_cell.touch_node.ani_node"]:setAnchoredPosition(0, 0) uiMap["grid_cell.touch_node.ani_node"]:setAnchoredPosition(0, 0)
uiMap["grid_cell.touch_node.ani_node"]:setLocalScale(1, 1, 1) uiMap["grid_cell.touch_node.ani_node"]:setLocalScale(1, 1, 1)
end end