diff --git a/lua/app/common/bi_report.lua b/lua/app/common/bi_report.lua index 85e3bb3e..33c72ddd 100644 --- a/lua/app/common/bi_report.lua +++ b/lua/app/common/bi_report.lua @@ -256,6 +256,18 @@ function BIReport:report(name, args) if DataManager.PlayerData then args.player_level = DataManager.PlayerData:getLv() end + + args.formation_atk = 0 + args.formation_hp = 0 + if DataManager.FormationData then + for matchType, heroId in pairs(DataManager.FormationData:getStageFormation()) do + local entity = DataManager.HeroData:getHeroById(heroId) + if entity then + args.formation_atk = args.formation_atk + entity:getAtk() + args.formation_hp = args.formation_hp + entity:getHp() + end + end + end end args.current_version = CS.BF.BFMain.Instance.GameLaunchMgr:GetCurrentVersion() args.is_new_player = self.isNewPlayer @@ -383,6 +395,14 @@ function BIReport:postGameLoginFinish() -- is_daily_first = DataManager:getIsTodayFirstLogin(), -- is_first = DataManager:getIsFirstLogin(), } + for heroId, entity in pairs(DataManager.HeroData:getAllHeroes()) do + if args.all_heros then + args.all_heros = args.all_heros .. "|" + else + args.all_heros = GConst.EMPTY_STRING + end + args.all_heros = args.all_heros .. heroId .. ":" .. entity:getLv() + end self:report(EVENT_NAME_LOGIN_FINISH, args) end @@ -407,6 +427,21 @@ function BIReport:postFightBegin(battleType, wave, chapterId, maxChapter, startT max_chapter = maxChapter, start_times = startTimes, } + local famation_level = 0 + local formation = DataManager.FormationData:getStageFormation() + for matchType, heroId in pairs(formation) do + local entity = DataManager.HeroData:getHeroById(heroId) + if entity then + if args.formation then + args.formation = args.formation .. "|" + else + args.formation = GConst.EMPTY_STRING + end + args.formation = args.formation .. heroId .. ":" .. entity:getLv() + famation_level = famation_level + entity:getLv() + end + end + args.famation_level = famation_level self:report(EVENT_NAME_FIGHT, args) end @@ -444,22 +479,22 @@ function BIReport:postFightEnd(battleType, chapterId, wave, duration, totalTime, is_first_win = isFirstWin, isFianlStep = isFianlStep, } - if isFianlStep then - local famation_level = 0 - local formation = DataManager.FormationData:getStageFormation() - for matchType, heroId in pairs(formation) do - local entity = DataManager.HeroData:getHeroById(heroId) - if entity then - if args.formation then - args.formation = args.formation .. "|" - else - args.formation = GConst.EMPTY_STRING - end - args.formation = args.formation .. heroId .. ":" .. entity:getLv() - famation_level = famation_level + entity:getLv() + local famation_level = 0 + local formation = DataManager.FormationData:getStageFormation() + for matchType, heroId in pairs(formation) do + local entity = DataManager.HeroData:getHeroById(heroId) + if entity then + if args.formation then + args.formation = args.formation .. "|" + else + args.formation = GConst.EMPTY_STRING end + args.formation = args.formation .. heroId .. ":" .. entity:getLv() + famation_level = famation_level + entity:getLv() end - args.famation_level = famation_level + end + args.famation_level = famation_level + if isFianlStep then args.maxLinkCount = maxLinkCount end diff --git a/lua/app/module/maincity/maincity_manager.lua b/lua/app/module/maincity/maincity_manager.lua index 2e06fb85..09b004e2 100644 --- a/lua/app/module/maincity/maincity_manager.lua +++ b/lua/app/module/maincity/maincity_manager.lua @@ -19,7 +19,6 @@ function MaincityManager:firstEnterMainCity() DataManager.ChapterData:setChapterId(DataManager.ChapterData.MIN_CHAPTER_ID) ModuleManager.BattleManager:playBattle(GConst.BattleConst.BATTLE_TYPE.STAGE) else - BIReport:postGameLoginFinish() self:showMainCityUI(true) end SDKManager:doUncompletePay() diff --git a/lua/app/ui/main_city/component/chapter_comp.lua b/lua/app/ui/main_city/component/chapter_comp.lua index 833d1b68..182ac533 100644 --- a/lua/app/ui/main_city/component/chapter_comp.lua +++ b/lua/app/ui/main_city/component/chapter_comp.lua @@ -147,7 +147,6 @@ function ChapterComp:refreshChapter(force) if needWave <= curMaxWave and not rewardGot then objs.spineObj:setVisible(true) objs.spineObj:playAnimComplete("open", true, false, function() - objs.spineObj:setVisible(false) ModuleManager.ChapterManager:openBox(rewardChapterId, index) end) else