This commit is contained in:
xiekaidong 2023-04-21 10:57:34 +08:00
commit 01e691fceb

View File

@ -50,6 +50,9 @@ function ChapterManager:endFight(id, combatReport)
}
ServerDataManager:dataOperate(GConst.ServerDataConst.DATA_OP_BEHAVIOR.END_FIGHT, parmas, function(result)
if result.status == 0 then
if combatReport.victory and DataManager.ChapterData:getChapterId() == DataManager.ChapterData:getMaxChapterId() + 1 then
DataManager.ChapterData:goNextChapter()
end
GFunc.addRewards(result.rewards, BIReport.ITEM_GET_TYPE.FIGHT_END)
ModuleManager.BattleManager:showBattleResultUI(result.rewards, combatReport)
DataManager.ChapterData:init(result.chapterData, true)