diff --git a/lua/app/module/battle/controller/battle_controller_pvp.lua b/lua/app/module/battle/controller/battle_controller_pvp.lua index ef91dfb1..222ce6ff 100644 --- a/lua/app/module/battle/controller/battle_controller_pvp.lua +++ b/lua/app/module/battle/controller/battle_controller_pvp.lua @@ -217,6 +217,8 @@ function BattleControllerPVP:onFillBoardOver(...) for posId, entity in pairs(self.battleData:getGridEnties()) do if self:getPosIdInCurActionBoardRowRange(posId) and entity:getSkillId() then if entity:getSkillSide() ~= self.curActionSide then + local team = self:getSideTeam(self.curActionSide) + local unitComp = team:getMainUnit() local skillMatchType = entity:getSkillMatchType() if skillMatchType then local skillEntity = self.battleData:getSkillEntityByElement(skillMatchType, self.curActionSide) @@ -224,6 +226,15 @@ function BattleControllerPVP:onFillBoardOver(...) entity:setSkilId(skillEntity:getSkillId(), false, self.curActionSide) self.battleUI:playChangeElementSfx(posId, index) index = index + 1 + if unitComp.unitEntity then + if unitComp.unitEntity:getActiveSkillLimit() then + entity:setGridType(BattleConst.GRID_TYPE.LOCK) + else + entity:setGridType(BattleConst.GRID_TYPE.EMPTY) + end + else + entity:setGridType(BattleConst.GRID_TYPE.EMPTY) + end end end end