From 69dc46402f4256578584a21969281154ce7f9751 Mon Sep 17 00:00:00 2001 From: puxuan <413323644@qq.com> Date: Mon, 27 Oct 2025 18:35:17 +0800 Subject: [PATCH] fix bug --- lua/app/common/bi_report.lua | 4 ++++ lua/app/common/data_manager.lua | 2 +- lua/app/common/module_manager.lua | 1 + .../localization/localization_global_const.lua | 1 + lua/app/config/strings/cn/global.lua | 1 + lua/app/config/talent.lua | 2 +- lua/app/global/global_const.lua | 9 --------- lua/app/global/global_func.lua | 2 +- lua/app/module/battle/battle_manager.lua | 6 ++++++ .../battle/controller/battle_base_controller.lua | 7 +++++++ .../battle_controller_daily_challenge.lua | 3 +-- .../battle/helper/battle_board_touch_helper.lua | 2 ++ lua/app/module/chapter/chapter_manager.lua | 1 + lua/app/ui/arena/arena_ui.lua | 2 +- lua/app/ui/battle/battle_result_ui.lua | 2 +- lua/app/ui/battle/battle_skill_select_comp.lua | 14 ++++++++++++-- lua/app/ui/common/cell/reward_cell.lua | 12 ++++++++++++ lua/app/ui/hero/hero_skin_ui.lua | 2 +- .../ui/main_city/cell/side_bar_act_sprint_cell.lua | 2 +- lua/app/ui/talent/talent_main_ui.lua | 11 +++++++++++ .../activity/act_sprint/act_sprint_data.lua | 2 +- .../act_sprint/act_sprint_summon_data_all.lua | 2 +- lua/app/userdata/talent/talent_data.lua | 11 +++-------- 23 files changed, 71 insertions(+), 30 deletions(-) diff --git a/lua/app/common/bi_report.lua b/lua/app/common/bi_report.lua index 24f87fac..2394424c 100644 --- a/lua/app/common/bi_report.lua +++ b/lua/app/common/bi_report.lua @@ -255,6 +255,10 @@ BIReport.ADS_CLICK_TYPE = { AD_ACT_SEVEN_DAY_GIFT = "AdActSevenDayGift", AD_ACT_SPRINT = "AdActSprint", -- 冲刺活动 + + AD_SHOP_GOLD = "AdShopGold", + AD_DAILY_SHOP = "AdDailyShop", + AD_DAILY_SHOP_REFRESH = "AdDailyShopRefresh", } BIReport.FIGHT_OPT_TYPE = { diff --git a/lua/app/common/data_manager.lua b/lua/app/common/data_manager.lua index 2929bf9e..a51f1d3a 100644 --- a/lua/app/common/data_manager.lua +++ b/lua/app/common/data_manager.lua @@ -157,7 +157,7 @@ function DataManager:initWithServerData(data) self.ShopData:init() self.ShopData:refreshDailyShop(data.mall_daily_store) self.PrivilegeCardData:init(data.card) - -- self.ShopData:refreshGoldShop(data.mall_gold) + self.ShopData:refreshGoldShop(data.mall_gold) -- self.ShopData:refreshEmblemShop(data.mall_mythic_store) -- self.ShopData:initVit(data.energy_limit) -- self.ShopData:initThirdPayOrder(data.third_pay) diff --git a/lua/app/common/module_manager.lua b/lua/app/common/module_manager.lua index 24d0c6c3..c0e631e1 100644 --- a/lua/app/common/module_manager.lua +++ b/lua/app/common/module_manager.lua @@ -131,6 +131,7 @@ ModuleManager.MODULE_KEY = { -- 七天乐 ACT_SEVENDAY = "act_sevenday", ACT_SEVENDAY_2 = "act_sevenday_2", + ACT_GOGOGO = "act_gogogo", -- 免广告卡 CARD_AD = "card_ad", DUNGEON_GOLD = "dungeon_gold", -- 金币副本 diff --git a/lua/app/config/localization/localization_global_const.lua b/lua/app/config/localization/localization_global_const.lua index 43035f69..994b1cc0 100644 --- a/lua/app/config/localization/localization_global_const.lua +++ b/lua/app/config/localization/localization_global_const.lua @@ -960,6 +960,7 @@ local LocalizationGlobalConst = FUND_CHAPTER_TAG_DESC_20 = "FUND_CHAPTER_TAG_DESC_20", FUND_CHAPTER_TAG_DESC_21 = "FUND_CHAPTER_TAG_DESC_21", FUND_CHAPTER_TAG_DESC_22 = "FUND_CHAPTER_TAG_DESC_22", + TALENT_HELP = "TALENT_HELP", } return LocalizationGlobalConst \ No newline at end of file diff --git a/lua/app/config/strings/cn/global.lua b/lua/app/config/strings/cn/global.lua index 4743bd8a..b46fdcf1 100644 --- a/lua/app/config/strings/cn/global.lua +++ b/lua/app/config/strings/cn/global.lua @@ -960,6 +960,7 @@ local localization_global = ["FUND_CHAPTER_TAG_DESC_20"] = "关卡基金20", ["FUND_CHAPTER_TAG_DESC_21"] = "关卡基金21", ["FUND_CHAPTER_TAG_DESC_22"] = "关卡基金22", + ["TALENT_HELP"] = "天赋帮助", } return localization_global \ No newline at end of file diff --git a/lua/app/config/talent.lua b/lua/app/config/talent.lua index c128d325..2aebe58f 100644 --- a/lua/app/config/talent.lua +++ b/lua/app/config/talent.lua @@ -141,7 +141,7 @@ local talent = { ["qlt"]=3, ["attr"]={ { - ["type"]="attr_atkp_all", + ["type"]="attr_hpp_all", ["num"]=500 } }, diff --git a/lua/app/global/global_const.lua b/lua/app/global/global_const.lua index 84447266..53fa81bb 100644 --- a/lua/app/global/global_const.lua +++ b/lua/app/global/global_const.lua @@ -509,15 +509,6 @@ GConst.HERO_FRAME_BG_QLT = { [7] = "hero_frame_bg_7", } -GConst.QLT_COLOR = { - [1] = "#aef1ff", - [2] = "#9aff9c", - [3] = "#aef1ff", - [4] = "#f6aeff", - [5] = "#f6aeff", - [6] = "#f6aeff", -} - -- 没描边的文本颜色 GConst.QLT_COLOR_NO_OUTLINE = { [0] = "#FFFFFF", diff --git a/lua/app/global/global_func.lua b/lua/app/global/global_func.lua index 4ffed16e..09a7c308 100644 --- a/lua/app/global/global_func.lua +++ b/lua/app/global/global_func.lua @@ -1937,7 +1937,7 @@ end -- 通用 function GFunc.getQltColor(qlt) qlt = qlt or GConst.QLT_TYPE.NORMAL - return GConst.QLT_COLOR[qlt] + return GConst.QUALITY_TYPE[qlt] end -- 无描边用 diff --git a/lua/app/module/battle/battle_manager.lua b/lua/app/module/battle/battle_manager.lua index 56d55821..1f7ab9bb 100644 --- a/lua/app/module/battle/battle_manager.lua +++ b/lua/app/module/battle/battle_manager.lua @@ -201,6 +201,12 @@ function BattleManager:onSelectSkill(skillId, value, pos) self.battleController:onSelectSkill(skillId, value, pos) end +function BattleManager:clearSnap() + if self.battleController then + self.battleController:clearSnap() + end +end + function BattleManager:endBattleAndExit(proactivelyExit) if self.battleController then if proactivelyExit then diff --git a/lua/app/module/battle/controller/battle_base_controller.lua b/lua/app/module/battle/controller/battle_base_controller.lua index 043dd52c..cdd2c76c 100644 --- a/lua/app/module/battle/controller/battle_base_controller.lua +++ b/lua/app/module/battle/controller/battle_base_controller.lua @@ -1530,6 +1530,8 @@ function BattleBaseController:calculateCurElimination(onlyCheck) lineCount = lineCount + 1 linkElementType = elementType end + elseif info.isUniversal then + self.elementTypeMap[0] = (self.elementTypeMap[0] or 0) + 1 end end if entity:getEffectType() and info.isIdle then @@ -2356,6 +2358,7 @@ function BattleBaseController:getRandomGridInfo() if self.atkTeam:checkUniversal() and not self.battleData:hadUniversalGrid() then isUniversal = true end + isUniversal = true end return {gridType = gridType, elementType = elementType, isUniversal = isUniversal} @@ -3371,6 +3374,10 @@ function BattleBaseController:clear() end end +function BattleBaseController:clearSnap() + BATTLE_SNAPSHOT_HELPER:clearSnap(self) +end + function BattleBaseController:endBattleAndExit() BATTLE_SNAPSHOT_HELPER:clearSnap(self) ModuleManager.BattleManager:exitBattle() diff --git a/lua/app/module/battle/controller/battle_controller_daily_challenge.lua b/lua/app/module/battle/controller/battle_controller_daily_challenge.lua index 7d206eba..28bf4ec7 100644 --- a/lua/app/module/battle/controller/battle_controller_daily_challenge.lua +++ b/lua/app/module/battle/controller/battle_controller_daily_challenge.lua @@ -26,8 +26,7 @@ function BattleControllerDailyChallenge:getChapterConfig() end function BattleControllerDailyChallenge:getChapterId() - -- return DataManager.DailyChallengeData:getChapterDailyId() - return DataManager.DailyChallengeData:getDiffLv() + return DataManager.DailyChallengeData:getChapterDailyId() end function BattleControllerDailyChallenge:getBuffs() diff --git a/lua/app/module/battle/helper/battle_board_touch_helper.lua b/lua/app/module/battle/helper/battle_board_touch_helper.lua index c8b56ee7..853283d1 100644 --- a/lua/app/module/battle/helper/battle_board_touch_helper.lua +++ b/lua/app/module/battle/helper/battle_board_touch_helper.lua @@ -265,6 +265,8 @@ function BattleBoardTouchHelper:clearSequenceByPosId(posId) end end end + else + currElementType = gridEntity:getElementType(skillEntity, true) end local _, skillPosId = self.battleData:getSequenceHadSkill() diff --git a/lua/app/module/chapter/chapter_manager.lua b/lua/app/module/chapter/chapter_manager.lua index 72d82dae..82db56b9 100644 --- a/lua/app/module/chapter/chapter_manager.lua +++ b/lua/app/module/chapter/chapter_manager.lua @@ -127,6 +127,7 @@ function ChapterManager:endFightFinish(result) end end + ModuleManager.BattleManager:clearSnap() ModuleManager.BattleManager:showBattleResultUI(GConst.BattleConst.BATTLE_TYPE.STAGE, newRewards, reqData.combatReport, mysteryBoxIdx, nil, true) DataManager.ChapterData:fightChapter(reqData.chapter_id, result.max_chapter_id, result.max_wave, reqData.mystery_box_idx) DataManager.ChapterData:clearChapterBoxState() diff --git a/lua/app/ui/arena/arena_ui.lua b/lua/app/ui/arena/arena_ui.lua index fd5dbc59..bf6d6288 100644 --- a/lua/app/ui/arena/arena_ui.lua +++ b/lua/app/ui/arena/arena_ui.lua @@ -72,7 +72,7 @@ function ArenaUI:onLoadRootComplete() self.btnHelp:addClickListener(function() local params = { - type = GConst.TipsConst.HELP_TIPS_TYPE.ARENA, + type = GConst.TipsConst.HELP_TIPS_TYPE.NORMAL, title = I18N:getGlobalText(I18N.GlobalConst.ARENA_DESC_4), desc = I18N:getGlobalText(I18N.GlobalConst.ARENA_DESC_HELP), } diff --git a/lua/app/ui/battle/battle_result_ui.lua b/lua/app/ui/battle/battle_result_ui.lua index 4b9d40c9..bc6e59b9 100644 --- a/lua/app/ui/battle/battle_result_ui.lua +++ b/lua/app/ui/battle/battle_result_ui.lua @@ -381,7 +381,7 @@ function BattleResultUI:refreshRewards() cell:showRightUpIcon(index <= self.mysteryBoxIdx, GConst.ATLAS_PATH.COMMON, "common_chest_1") cell:showFirstPass(index <= self.firstPassIdx) if self.isDouble then - cell:setNumTx(self.rewards[index].num * 2) + cell:setNumTxDouble() end end) if self:hasArenaBoxNode() then diff --git a/lua/app/ui/battle/battle_skill_select_comp.lua b/lua/app/ui/battle/battle_skill_select_comp.lua index 1b4009d0..fed0fd85 100644 --- a/lua/app/ui/battle/battle_skill_select_comp.lua +++ b/lua/app/ui/battle/battle_skill_select_comp.lua @@ -99,11 +99,12 @@ function BattleSkillSelectComp:refreshBtns() getAllAdCount = GFunc.getConstIntValue("daily_challenge_ads_getall_rogue_limit") end local allCount = battleController.battleData:getAllSkillCount() + local showAll = false + local showAd = false if getAllAdCount > allCount then - adBtn:setAnchoredPositionX(-102) allBtn:setActive(true) + showAll = true else - adBtn:setAnchoredPositionX(0) allBtn:setActive(false) end @@ -118,9 +119,18 @@ function BattleSkillSelectComp:refreshBtns() local adCount = battleController.battleData:getADRefreshSkillCount() if cfgAdCount > adCount then adBtn:setActive(true) + showAd = true else adBtn:setActive(false) end + if showAll and showAd then + allBtn:setAnchoredPositionX(102) + adBtn:setAnchoredPositionX(-102) + elseif showAll then + allBtn:setAnchoredPositionX(0) + elseif showAd then + adBtn:setAnchoredPositionX(0) + end end function BattleSkillSelectComp:getNewRandomSkill(parmas) diff --git a/lua/app/ui/common/cell/reward_cell.lua b/lua/app/ui/common/cell/reward_cell.lua index a10cb6e8..b80c45cc 100644 --- a/lua/app/ui/common/cell/reward_cell.lua +++ b/lua/app/ui/common/cell/reward_cell.lua @@ -111,6 +111,7 @@ function RewardCell:_refreshItem(info, count) else self.numTx:setText(GFunc.intToString(count)) end + self.count = count else self.numTx:setText(GConst.EMPTY_STRING) end @@ -175,6 +176,17 @@ function RewardCell:setIconSprite(atlas, res) self.icon:setSprite(atlas, res) end +function RewardCell:setNumTxDouble() + if self.count then + local count = self.count * 2 + if count > 100 then + self.numTx:setText(GFunc.num2Str(count)) + else + self.numTx:setText(GFunc.intToString(count)) + end + end +end + function RewardCell:setNumTx(str) self.numTx:setText(str) end diff --git a/lua/app/ui/hero/hero_skin_ui.lua b/lua/app/ui/hero/hero_skin_ui.lua index d53e574c..a86a43b0 100644 --- a/lua/app/ui/hero/hero_skin_ui.lua +++ b/lua/app/ui/hero/hero_skin_ui.lua @@ -95,7 +95,7 @@ function HeroSkinUI:refreshSelectSkin(selectId) local qlt = DataManager.SkinData:getSkinCfg(self.selectSkinId).qlt self.bgQlt:setSprite(GConst.ATLAS_PATH.HERO, "hero_skin_bg_" .. qlt) self.iconQlt:setSprite(GConst.ATLAS_PATH.HERO, "hero_skin_" .. qlt) - self.txQlt:setText("" .. I18N:getGlobalText("QLT_DESC_" .. qlt) .. "") + self.txQlt:setText("" .. I18N:getGlobalText("QLT_DESC_" .. qlt) .. "") self.txName:setText(DataManager.SkinData:getName(self.selectSkinId)) -- 属性 diff --git a/lua/app/ui/main_city/cell/side_bar_act_sprint_cell.lua b/lua/app/ui/main_city/cell/side_bar_act_sprint_cell.lua index 258a2c79..063bf31d 100755 --- a/lua/app/ui/main_city/cell/side_bar_act_sprint_cell.lua +++ b/lua/app/ui/main_city/cell/side_bar_act_sprint_cell.lua @@ -1,6 +1,6 @@ local SideBarActSprintCell = class("SideBarActSprintCell", SideBarBaseCell) function SideBarActSprintCell:getModuleKey() - return ModuleManager.MODULE_KEY.ACTIVITY + return ModuleManager.MODULE_KEY.ACT_GOGOGO end function SideBarActSprintCell:getIsOpen() diff --git a/lua/app/ui/talent/talent_main_ui.lua b/lua/app/ui/talent/talent_main_ui.lua index d4ad179f..38194384 100644 --- a/lua/app/ui/talent/talent_main_ui.lua +++ b/lua/app/ui/talent/talent_main_ui.lua @@ -58,6 +58,7 @@ function TalentMainUI:onLoadRootComplete() uiMap["talent_ui.title_tx"]:setText(I18N:getGlobalText(I18N.GlobalConst.TALENT_DESC_1)) uiMap["talent_ui.get_btn.text"]:setText(I18N:getGlobalText(I18N.GlobalConst.TALENT_DESC_2)) + uiMap["talent_ui.up_node.continue"]:setText(I18N:getGlobalText(I18N.GlobalConst.CLICK_CLOSE_DESC)) self.scrollRect = uiMap["talent_ui.bottom_bg.scrollrect"]:addLuaComponent(GConst.TYPEOF_LUA_CLASS.SCROLL_RECT_BASE) self.scrollRect:addInitCallback(function() return TALENT_CELL @@ -67,6 +68,16 @@ function TalentMainUI:onLoadRootComplete() end) self.scrollRect:clearCells() + local helpBtn = uiMap["talent_ui.top_bg.help_btn"] + helpBtn:addClickListener(function() + ModuleManager.TipsManager:showDescTips(I18N:getGlobalText(I18N.GlobalConst.TALENT_HELP), helpBtn) + local params = { + type = GConst.TipsConst.HELP_TIPS_TYPE.NORMAL, + desc = I18N:getGlobalText(I18N.GlobalConst.TALENT_HELP), + } + ModuleManager.TipsManager:showHelpTips(params) + end) + self.getBtn:addClickListener(function() if not GFunc.checkCost(self.cfg.cost.id, self.cfg.cost.num, true) then return diff --git a/lua/app/userdata/activity/act_sprint/act_sprint_data.lua b/lua/app/userdata/activity/act_sprint/act_sprint_data.lua index 756d4c65..69241306 100644 --- a/lua/app/userdata/activity/act_sprint/act_sprint_data.lua +++ b/lua/app/userdata/activity/act_sprint/act_sprint_data.lua @@ -68,7 +68,7 @@ function ActSprintData:getSprintDetailData(actId) end function ActSprintData:getIsOpen() - if not ModuleManager:getIsOpen(ModuleManager.MODULE_KEY.ACTIVITY, true) then + if not ModuleManager:getIsOpen(ModuleManager.MODULE_KEY.ACT_GOGOGO, true) then return false end diff --git a/lua/app/userdata/activity/act_sprint/act_sprint_summon_data_all.lua b/lua/app/userdata/activity/act_sprint/act_sprint_summon_data_all.lua index 11e48bad..8241a025 100644 --- a/lua/app/userdata/activity/act_sprint/act_sprint_summon_data_all.lua +++ b/lua/app/userdata/activity/act_sprint/act_sprint_summon_data_all.lua @@ -251,7 +251,7 @@ function ActSprintSummonData:syncedData() end function ActSprintSummonData:getIsOpen() - if not ModuleManager:getIsOpen(ModuleManager.MODULE_KEY.ACTIVITY, true) then + if not ModuleManager:getIsOpen(ModuleManager.MODULE_KEY.ACT_GOGOGO, true) then return false end diff --git a/lua/app/userdata/talent/talent_data.lua b/lua/app/userdata/talent/talent_data.lua index d1f84faa..886f55f5 100644 --- a/lua/app/userdata/talent/talent_data.lua +++ b/lua/app/userdata/talent/talent_data.lua @@ -140,14 +140,9 @@ function TalentData:_updateAllAttr() -- 处理全局属性 local attr = {} - attr[GConst.ATTR_ALL.ATTR_ATK_ALL] = self.allAttr[GConst.ATTR_ALL.ATTR_ATK_ALL] - attr[GConst.ATTR_ALL.ATTR_HP_ALL] = self.allAttr[GConst.ATTR_ALL.ATTR_HP_ALL] - attr[GConst.ATTR_ALL.ATTR_DMGDEC_ALL] = self.allAttr[GConst.ATTR_ALL.ATTR_DMGDEC_ALL] - attr[GConst.ATTR_ALL.ATTR_CRIT_ALL] = self.allAttr[GConst.ATTR_ALL.ATTR_CRIT_ALL] - attr[GConst.ATTR_ALL.ATTR_CRIT_TIME_ALL] = self.allAttr[GConst.ATTR_ALL.ATTR_CRIT_TIME_ALL] - attr[GConst.ATTR_ALL.ATTR_NORMAL_HURTP_ALL] = self.allAttr[GConst.ATTR_ALL.ATTR_NORMAL_HURTP_ALL] - attr[GConst.ATTR_ALL.ATTR_SKILL_HURTP_ALL] = self.allAttr[GConst.ATTR_ALL.ATTR_SKILL_HURTP_ALL] - attr[GConst.ATTR_ALL.ATTR_ATKP_ALL] = self.allAttr[GConst.ATTR_ALL.ATTR_ATKP_ALL] + for _, v in pairs(GConst.ATTR_ALL) do + attr[v] = self.allAttr[v] + end DataManager.HeroData:setTalentAttr(attr)