Commit 1d45a501ef1c19f5554f621329e45242b4d728ff
1 parent
fa8ba58d
增加新的退出类型
Showing
1 changed file
with
9 additions
and
0 deletions
Show diff stats
src/adv/AdvMap.lua
@@ -65,6 +65,15 @@ function Map:checkOver() | @@ -65,6 +65,15 @@ function Map:checkOver() | ||
65 | if #self.adv.battle.player:getTeam(2) == 0 then return true end | 65 | if #self.adv.battle.player:getTeam(2) == 0 then return true end |
66 | elseif mapCsv.clearType == 3 then -- 持有 | 66 | elseif mapCsv.clearType == 3 then -- 持有 |
67 | if self.adv:cost(mapCsv.clear:toNumMap(), {}, true) then return true end | 67 | if self.adv:cost(mapCsv.clear:toNumMap(), {}, true) then return true end |
68 | + elseif mapCsv.clearType == 4 then | ||
69 | + for roomId, room in pairs(self.rooms) do | ||
70 | + for blockId, block in pairs(room.blocks) do | ||
71 | + if not block.isOpen then | ||
72 | + return false | ||
73 | + end | ||
74 | + end | ||
75 | + return true | ||
76 | + end | ||
68 | else | 77 | else |
69 | return true | 78 | return true |
70 | end | 79 | end |