bug修复
This commit is contained in:
parent
aca97b775e
commit
1a5f74708e
@ -925,7 +925,7 @@ function BattleBaseController:enterNextWaveBySnapshot(snapShot)
|
|||||||
self.curWaveMonsterDead = false
|
self.curWaveMonsterDead = false
|
||||||
self:refreshWave(self.waveIndex)
|
self:refreshWave(self.waveIndex)
|
||||||
self.needWaitingBoardOver = true
|
self.needWaitingBoardOver = true
|
||||||
self:generateBoard(true, snapShot.boardSnapInfo)
|
self:generateBoard(true, snapShot)
|
||||||
|
|
||||||
self.waveDurationTime = 0
|
self.waveDurationTime = 0
|
||||||
self.eliminateCount = 0
|
self.eliminateCount = 0
|
||||||
@ -1537,9 +1537,13 @@ function BattleBaseController:onFillBoardOver(isRoundBeginCheck)
|
|||||||
local index = table.remove(self.showMysteryBoxIndexs, 1)
|
local index = table.remove(self.showMysteryBoxIndexs, 1)
|
||||||
local boardList, _, mysteryBoxIndexMap = self:getInitBoard()
|
local boardList, _, mysteryBoxIndexMap = self:getInitBoard()
|
||||||
local rewards = mysteryBoxIndexMap[index]
|
local rewards = mysteryBoxIndexMap[index]
|
||||||
ModuleManager.BattleManager:showBoxOpenUI(rewards, function()
|
if rewards then
|
||||||
|
ModuleManager.BattleManager:showBoxOpenUI(rewards, function()
|
||||||
|
self:onFillBoardOver()
|
||||||
|
end)
|
||||||
|
else
|
||||||
self:onFillBoardOver()
|
self:onFillBoardOver()
|
||||||
end)
|
end
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -1620,6 +1624,9 @@ function BattleBaseController:generateBoard(isFirst, snapshot)
|
|||||||
end
|
end
|
||||||
|
|
||||||
self.curBoardIndex = (self.curBoardIndex or 0) + 1
|
self.curBoardIndex = (self.curBoardIndex or 0) + 1
|
||||||
|
if snapshot and snapshot.curBoardIndex then
|
||||||
|
self.curBoardIndex = snapshot.curBoardIndex
|
||||||
|
end
|
||||||
if not boardList[self.curBoardIndex] then -- 容错
|
if not boardList[self.curBoardIndex] then -- 容错
|
||||||
if isFirst then
|
if isFirst then
|
||||||
self.needWaitingBoardOver = false
|
self.needWaitingBoardOver = false
|
||||||
@ -1632,7 +1639,7 @@ function BattleBaseController:generateBoard(isFirst, snapshot)
|
|||||||
board = mysteryBoard
|
board = mysteryBoard
|
||||||
end
|
end
|
||||||
self.battleUI:switchBoard(function()
|
self.battleUI:switchBoard(function()
|
||||||
self.battleData:refreshBoard(board, self:getBlockIcon(), snapshot)
|
self.battleData:refreshBoard(board, self:getBlockIcon(), snapshot and snapshot.boardSnapInfo)
|
||||||
self.battleUI:initGridCell(function()
|
self.battleUI:initGridCell(function()
|
||||||
if isFirst then
|
if isFirst then
|
||||||
self.needWaitingBoardOver = false
|
self.needWaitingBoardOver = false
|
||||||
|
|||||||
@ -50,6 +50,7 @@ function BattleSnapshotHelper:snapshotBattleInfo(battleBaseController)
|
|||||||
for k, v in pairs(battleBaseController.lastRoundBreakedGridType) do
|
for k, v in pairs(battleBaseController.lastRoundBreakedGridType) do
|
||||||
battleBaseController.snapShotInfo.lastRoundBreakedGridType[tostring(k)] = v
|
battleBaseController.snapShotInfo.lastRoundBreakedGridType[tostring(k)] = v
|
||||||
end
|
end
|
||||||
|
battleBaseController.snapShotInfo.curBoardIndex = battleBaseController.curBoardIndex
|
||||||
battleBaseController.snapShotInfo.chapterId = battleBaseController.chapterId -- 当前战斗关卡
|
battleBaseController.snapShotInfo.chapterId = battleBaseController.chapterId -- 当前战斗关卡
|
||||||
battleBaseController.snapShotInfo.waveIndex = battleBaseController.waveIndex -- 当前波次
|
battleBaseController.snapShotInfo.waveIndex = battleBaseController.waveIndex -- 当前波次
|
||||||
battleBaseController.snapShotInfo.gotMysteryBoxIndexs = table.clearOrCreate(battleBaseController.snapShotInfo.gotMysteryBoxIndexs) -- 神秘宝箱索引
|
battleBaseController.snapShotInfo.gotMysteryBoxIndexs = table.clearOrCreate(battleBaseController.snapShotInfo.gotMysteryBoxIndexs) -- 神秘宝箱索引
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user