修改上报

This commit is contained in:
xiekaidong 2023-06-06 15:25:21 +08:00
parent 4d6e578982
commit 32df7d9516
4 changed files with 15 additions and 15 deletions

View File

@ -255,8 +255,8 @@ end
function BattleController:init(params) function BattleController:init(params)
params = params or {} params = params or {}
self.battleType = params.battleType or GConst.BattleConst.BATTLE_TYPE.STAGE self.battleType = params.battleType or GConst.BattleConst.BATTLE_TYPE.STAGE
self.battleStartTime = Time:getServerTime() self.waveDurationTime = 0
self.waveStartTime = Time:getServerTime() self.totalDurationTime = 0
self.eliminateCount = 0 self.eliminateCount = 0
self.eliminateTotalCount = 0 self.eliminateTotalCount = 0
self.realTime = 0 self.realTime = 0
@ -446,8 +446,8 @@ function BattleController:battleStart()
self.atkTeam:prepare() self.atkTeam:prepare()
self.defTeam:prepare() self.defTeam:prepare()
self.isBattleStart = true self.isBattleStart = true
self.tickSid = BattleScheduler:scheduleGlobal(function(dt) self.tickSid = BattleScheduler:scheduleGlobal(function(dt, originDt)
self:_tick(dt) self:_tick(dt, originDt)
end, 0) end, 0)
self:enterNextWave() self:enterNextWave()
end end
@ -538,7 +538,7 @@ function BattleController:enterNextWave()
self.defTeam:prepare() self.defTeam:prepare()
end end
self.waveStartTime = Time:getServerTime() self.waveDurationTime = 0
self.eliminateCount = 0 self.eliminateCount = 0
self.isBossWave = self.defTeam:getMainUnit().unitEntity:getIsBoss() self.isBossWave = self.defTeam:getMainUnit().unitEntity:getIsBoss()
@ -1219,8 +1219,7 @@ function BattleController:tryShowSelectSkillComp(needDelay, onlyCommonSkill)
self.battleUI:showSelectSkillComp(skillList, onlyCommonSkill) self.battleUI:showSelectSkillComp(skillList, onlyCommonSkill)
end end
local totalTime = Time:getServerTime() - self.battleStartTime BIReport:postShowFightSkillSelect(self.battleType, skillList, self.chapterId, self.totalDurationTime, self.waveIndex)
BIReport:postShowFightSkillSelect(self.battleType, skillList, self.chapterId, totalTime, self.waveIndex)
end end
function BattleController:fillBoard(isRoundBeginCheck) function BattleController:fillBoard(isRoundBeginCheck)
@ -1885,8 +1884,7 @@ function BattleController:onSelectSkill(skillId, value, pos)
entity:gotUpSKill(skillId) entity:gotUpSKill(skillId)
end end
local totalTime = Time:getServerTime() - self.battleStartTime BIReport:postFightSkillSelect(self.battleType, {skillId}, self.chapterId, self.totalDurationTime, self.waveIndex)
BIReport:postFightSkillSelect(self.battleType, {skillId}, self.chapterId, totalTime, self.waveIndex)
local elementType = ModuleManager.HeroManager:getSkillRoguePosition(skillId) local elementType = ModuleManager.HeroManager:getSkillRoguePosition(skillId)
@ -2525,8 +2523,10 @@ function BattleController:reduceFillWaitingCount()
self.waitingFillCount = self.waitingFillCount - 1 self.waitingFillCount = self.waitingFillCount - 1
end end
function BattleController:_tick(dt) function BattleController:_tick(dt, originDt)
self.realTime = self.realTime + dt self.realTime = self.realTime + dt
self.waveDurationTime = self.waveDurationTime + originDt
self.totalDurationTime = self.totalDurationTime + originDt
if self.isPause then if self.isPause then
return return
end end

View File

@ -257,8 +257,8 @@ function BattleControllerDailyChallenge:postWaveOver(atkDead, isQuit)
waveEndType = BIReport.FIGHT_WAVE_END_TYPE.QUIT waveEndType = BIReport.FIGHT_WAVE_END_TYPE.QUIT
end end
local duration = Time:getServerTime() - self.waveStartTime local duration = self.waveDurationTime
local totalTime = Time:getServerTime() - self.battleStartTime local totalTime = self.totalDurationTime
local startTimes = DataManager.DailyChallengeData:getTotalFightCount() local startTimes = DataManager.DailyChallengeData:getTotalFightCount()
local isFirstWin = false -- TODO 策划说不需要 因为系数在变 local isFirstWin = false -- TODO 策划说不需要 因为系数在变

View File

@ -219,8 +219,8 @@ function BattleControllerStage:postWaveOver(atkDead, isQuit)
waveEndType = BIReport.FIGHT_WAVE_END_TYPE.QUIT waveEndType = BIReport.FIGHT_WAVE_END_TYPE.QUIT
end end
local duration = Time:getServerTime() - self.waveStartTime local duration = self.waveDurationTime
local totalTime = Time:getServerTime() - self.battleStartTime local totalTime = self.totalDurationTime
local startTimes = DataManager.ChapterData:getChapterFightCount(self.chapterId) local startTimes = DataManager.ChapterData:getChapterFightCount(self.chapterId)
local isFirstWin = false local isFirstWin = false
if not DataManager.ChapterData:getChapterPassed(self.chapterId) and self.victory then if not DataManager.ChapterData:getChapterPassed(self.chapterId) and self.victory then

View File

@ -47,7 +47,7 @@ function BattleScheduler:update(dt)
info.tick = info.tick - info.inter info.tick = info.tick - info.inter
info.waitRemove = true info.waitRemove = true
if info.func then if info.func then
local s = info.func(inter) local s = info.func(inter, dt)
local stop = not info.rep or s local stop = not info.rep or s
if stop then if stop then
self.dirty = true self.dirty = true