bug和引导

This commit is contained in:
xiekaidong 2023-04-21 19:48:08 +08:00
parent 5982d0083a
commit 806ab5170f
6 changed files with 50 additions and 19 deletions

View File

@ -1,14 +1,14 @@
local fx = {
[100000]={
["res"]="sfx_m10001_b01",
["res"]="sfx_m10001_b01_01",
["bind"]="root"
},
[100001]={
["res"]="sfx_m10001_b02",
["res"]="sfx_m10001_b01_02",
["bind"]="root"
},
[100002]={
["res"]="sfx_m10001_b03",
["res"]="sfx_m10001_b01_03",
["bind"]="root"
},
[100003]={

View File

@ -5,15 +5,15 @@ local tutorial_start = {
},
[2]={
["start_id"]=20000,
["uires_path"]="Assets/prefabs/ui/main_city/main_ui.prefab"
["uires_path"]="assets/prefabs/ui/main_city/main_ui.prefab"
},
[3]={
["start_id"]=30000,
["uires_path"]="Assets/prefabs/ui/main_city/main_ui.prefab"
["uires_path"]="assets/prefabs/ui/main_city/main_ui.prefab"
},
[4]={
["start_id"]=40000,
["uires_path"]="Assets/prefabs/ui/main_city/main_ui.prefab"
["uires_path"]="assets/prefabs/ui/main_city/main_ui.prefab"
}
}
local config = {

View File

@ -399,7 +399,11 @@ function BattleController:enterEliminationBegin()
end
function BattleController:enterElimination()
self.roundStep = BattleConst.BATTLE_ROUND_STEP.ON_ELIMINATION
if self.battleData:useAddlvCount() then
ModuleManager.BattleManager:showSelectSkillUI(self:getRandomSkillList())
else
self.roundStep = BattleConst.BATTLE_ROUND_STEP.ON_ELIMINATION
end
end
function BattleController:enterAtkStep()
@ -490,14 +494,10 @@ function BattleController:enterRoundEnd()
end
function BattleController:onRoundEnd(toNextWave)
if self.battleData:useAddlvCount() then
ModuleManager.BattleManager:showSelectSkillUI(self:getRandomSkillList())
if toNextWave then
self:enterNextWave()
else
if toNextWave then
self:enterNextWave()
else
self:enterRoundBegin()
end
self:enterRoundBegin()
end
end
@ -1439,7 +1439,7 @@ function BattleController:onSelectSkill(skillId, value)
entity:gotUpSKill(skillId)
end
self:onRoundEnd()
self:enterElimination()
if self.battleUI then
self.battleUI:refreshBoard()

View File

@ -29,6 +29,7 @@ function TutorialManager:sendTutorialId(id, callback)
end
function TutorialManager:sendTutorialIdFinish(result)
Logger.printTable(result)
if result.status == 0 then
if result.id then
-- BIReport:postTutorialStep(result.id)
@ -217,10 +218,12 @@ end
function TutorialManager:showFuncTutorial(id)
self:sendTutorialId(id, function(success)
Logger.logHighlight(success)
if success then
if not DataManager.TutorialData:getIsFuncTutorialFinished(id) then
DataManager.TutorialData:markFuncTutorialFinish(id)
local uires = DataManager.TutorialData:getTutorialId2UIPath(id)
Logger.logHighlight(uires)
if uires == nil or uires == "" then
self:showTutorial()
else

View File

@ -297,10 +297,10 @@ function MainCityUI:checkMainPop()
-- end
-- end
-- -- 引导
-- if self:checkTutorial() then
-- return
-- end
-- 引导
if self:checkTutorial() then
return
end
end
-- 检查引导
@ -318,6 +318,25 @@ function MainCityUI:checkTutorial()
-- return
-- end
-- end
Logger.logHighlight(DataManager.ChapterData:getMaxChapterId())
if DataManager.ChapterData:getMaxChapterId() == 1 then
if ModuleManager.TutorialManager:checkFuncTutorial(GConst.TutorialConst.PASS_ONE_CHAPTER) then
return
end
end
if DataManager.ChapterData:boxCanGet(2, 1) then
if ModuleManager.TutorialManager:checkFuncTutorial(GConst.TutorialConst.TWO_CHAPTER_BOX_CAN_GOT) then
return
end
end
if DataManager.ChapterData:getMaxChapterId() == 3 then
if ModuleManager.TutorialManager:checkFuncTutorial(GConst.TutorialConst.PASS_THREE_CHAPTER) then
return
end
end
end
return MainCityUI

View File

@ -132,6 +132,15 @@ function ChapterData:getChapterBoxRewardGot(chapterId, index)
return false
end
function ChapterData:boxCanGet(chapterId, index)
if self:getChapterBoxRewardGot(chapterId, index) then
return false
end
local needWave = DataManager.ChapterData:getChapterBoxNum(chapterId, index)
local curMaxWave = DataManager.ChapterData:getChapterMaxWave(chapterId)
return needWave <= curMaxWave
end
function ChapterData:getChapterBoxRewards(chapterId, index)
chapterId = chapterId or self:getChapterId()
if not self:getChapterBoxNum(chapterId, index) then