容错
This commit is contained in:
parent
1ab896c46b
commit
20bf29490f
@ -145,8 +145,8 @@ function BattleData:refreshBoard(board, blockIcon)
|
||||
local posId = ModuleManager.BattleManager:getPosId(r, c)
|
||||
local data = {
|
||||
posId = posId,
|
||||
gridType = info[1],
|
||||
elementType = info[2]
|
||||
gridType = info[1] or BattleConst.GRID_TYPE.EMPTY,
|
||||
elementType = info[2] or BattleConst.ELEMENT_TYPE.RED
|
||||
}
|
||||
if self.gridEntities[data.posId] then
|
||||
self.gridEntities[data.posId]:clear()
|
||||
@ -183,6 +183,8 @@ function BattleData:getElementTypeMap()
|
||||
for posId, entity in pairs(self.gridEntities) do
|
||||
if entity:canLink() then
|
||||
local elementType = entity:getElementType()
|
||||
Logger.logHighlight(posId)
|
||||
Logger.logHighlight(elementType)
|
||||
elementTypeMap[elementType] = (elementTypeMap[elementType] or 0) + 1
|
||||
end
|
||||
end
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user