From 150e128135e9322a834a81c07de7741e4e694f7a Mon Sep 17 00:00:00 2001 From: xiekaidong Date: Fri, 21 Apr 2023 16:49:27 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E5=85=B3=E5=8D=A1=E5=9B=BA=E5=AE=9A?= =?UTF-8?q?=E8=82=89=E9=B8=BD=E6=8A=80=E8=83=BD=E3=80=81=E6=8A=80=E8=83=BD?= =?UTF-8?q?=E5=8F=AF=E4=BB=A5=E5=BC=80=E5=A7=8B=E5=B0=B1=E4=BB=BB=E6=84=8F?= =?UTF-8?q?=E9=93=BE=E6=8E=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../module/battle/controller/battle_controller.lua | 6 ++++++ .../battle/controller/battle_controller_stage.lua | 13 +++++++++++++ .../battle/skill/battle_board_skill_entity.lua | 11 +++++++++++ 3 files changed, 30 insertions(+) diff --git a/lua/app/module/battle/controller/battle_controller.lua b/lua/app/module/battle/controller/battle_controller.lua index b40d42d9..a5f5d7fa 100644 --- a/lua/app/module/battle/controller/battle_controller.lua +++ b/lua/app/module/battle/controller/battle_controller.lua @@ -1330,6 +1330,12 @@ function BattleController:findSkillInfluenceGrids() end function BattleController:getRandomSkillList(getCount) + local fixedList = self:getFixedRogueSkill() + if fixedList[1] then + return table.remove(fixedList, 1) + end + + getCount = getCount or BattleConst.SKILL_SELECT_COUNT local result = {} local cfg = ConfigManager:getConfig("skill_rogue") diff --git a/lua/app/module/battle/controller/battle_controller_stage.lua b/lua/app/module/battle/controller/battle_controller_stage.lua index 0aa24fda..23f21a55 100644 --- a/lua/app/module/battle/controller/battle_controller_stage.lua +++ b/lua/app/module/battle/controller/battle_controller_stage.lua @@ -118,6 +118,19 @@ function BattleControllerStage:getNotInvolvedSkills() return self.notInvolvedSkills end +function BattleControllerStage:getFixedRogueSkill() + if not self.fixedRogueSkill then + local config = ConfigManager:getConfig("chapter")[self.chapterId] + if config.involved_skill then + self.fixedRogueSkill = GFunc.getTable(config.involved_skill) + else + self.fixedRogueSkill = {} + end + end + + return self.fixedRogueSkill +end + function BattleControllerStage:findNextDefUnit() self:_stageGenerateNextMonster() end diff --git a/lua/app/userdata/battle/skill/battle_board_skill_entity.lua b/lua/app/userdata/battle/skill/battle_board_skill_entity.lua index 10dd6574..97faaf66 100644 --- a/lua/app/userdata/battle/skill/battle_board_skill_entity.lua +++ b/lua/app/userdata/battle/skill/battle_board_skill_entity.lua @@ -153,6 +153,13 @@ function BattleBoardSkillEntity:getNameAct() return self.config.name_act end +function BattleBoardSkillEntity:cfgLinkAny() + if not self.config then + return false + end + return self.config.link ~= nil +end + function BattleBoardSkillEntity:getEnergy() return self.curEnergy end @@ -174,6 +181,10 @@ function BattleBoardSkillEntity:clearEnergy() end function BattleBoardSkillEntity:getIgnoreElementType() + if self:cfgLinkAny() then + return true + end + return self.ignoreElementType end From 57de5cf3e7928d581a46cc50745244b082809592 Mon Sep 17 00:00:00 2001 From: xiekaidong Date: Fri, 21 Apr 2023 16:50:54 +0800 Subject: [PATCH 2/3] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lua/app/config/monster_chapter.lua | 6 +++--- lua/app/config/skill.lua | 4 ++++ lua/app/config/tutorial.lua | 3 --- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/lua/app/config/monster_chapter.lua b/lua/app/config/monster_chapter.lua index 902e6db1..d4df2000 100644 --- a/lua/app/config/monster_chapter.lua +++ b/lua/app/config/monster_chapter.lua @@ -13,7 +13,7 @@ local monster_chapter = { ["atk"]=200000, ["atk_times"]=2, ["hurt_skill"]=1000001, - ["monster_exp"]=11000 + ["monster_exp"]=4000 }, [301]={ ["monster_base"]=10002, @@ -21,7 +21,7 @@ local monster_chapter = { ["atk"]=200000, ["atk_times"]=2, ["hurt_skill"]=1000001, - ["monster_exp"]=17000 + ["monster_exp"]=8000 }, [401]={ ["monster_base"]=10006, @@ -29,7 +29,7 @@ local monster_chapter = { ["atk"]=200000, ["atk_times"]=2, ["hurt_skill"]=1000000, - ["monster_exp"]=19000 + ["monster_exp"]=12000 }, [501]={ ["monster_base"]=20004, diff --git a/lua/app/config/skill.lua b/lua/app/config/skill.lua index 292a13f8..09362bbc 100644 --- a/lua/app/config/skill.lua +++ b/lua/app/config/skill.lua @@ -246,6 +246,7 @@ local skill = { }, [320011]={ ["energy"]=10, + ["link"]=1, ["position"]=3, ["method"]=2, ["skill_type"]=1, @@ -435,6 +436,7 @@ local skill = { }, [120011]={ ["energy"]=10, + ["link"]=1, ["position"]=1, ["method"]=2, ["skill_type"]=1, @@ -471,6 +473,7 @@ local skill = { }, [330011]={ ["energy"]=10, + ["link"]=1, ["position"]=3, ["method"]=1, ["skill_type"]=0, @@ -644,6 +647,7 @@ local skill = { }, [430011]={ ["energy"]=10, + ["link"]=1, ["position"]=4, ["method"]=1, ["skill_type"]=0, diff --git a/lua/app/config/tutorial.lua b/lua/app/config/tutorial.lua index e275a824..af73b73f 100644 --- a/lua/app/config/tutorial.lua +++ b/lua/app/config/tutorial.lua @@ -2,7 +2,6 @@ local tutorial = { [10000]={ ["next_id"]=10010, ["type"]=6, - ["finish"]=4, ["target_element"]={ 53, 44, @@ -33,7 +32,6 @@ local tutorial = { [10040]={ ["next_id"]=10050, ["type"]=6, - ["finish"]=4, ["target_element"]={ 33, 23, @@ -55,7 +53,6 @@ local tutorial = { }, [10060]={ ["type"]=6, - ["finish"]=4, ["target_element"]={ 23, 13, From 60a5d5551f89eee07ac769016396e5f20623b9a2 Mon Sep 17 00:00:00 2001 From: xiekaidong Date: Fri, 21 Apr 2023 17:05:36 +0800 Subject: [PATCH 3/3] =?UTF-8?q?=E5=88=9D=E5=A7=8B=E5=8C=96=E6=95=B0?= =?UTF-8?q?=E6=8D=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lua/app/server/server_game_data.lua | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lua/app/server/server_game_data.lua b/lua/app/server/server_game_data.lua index ebc08e84..e9aae108 100644 --- a/lua/app/server/server_game_data.lua +++ b/lua/app/server/server_game_data.lua @@ -50,6 +50,7 @@ function ServerGameData:initData() local heroCfg = ConfigManager:getConfig("hero") local heroLvCfg = ConfigManager:getConfig("hero_level") -- 如果初始化里面有碎片就直接合成 + local initHeroMap = {} local items = self.BagData.ItemData:getAllItems() for idStr, item in pairs(items) do local itemInfo = itemCfg[item.cfg_id] @@ -66,6 +67,7 @@ function ServerGameData:initData() if item.count >= needCout then item.count = item.count - needCout self.HeroData:addHero(heroCfgId, k) + initHeroMap[heroInfo.position] = heroCfgId end break end @@ -74,6 +76,9 @@ function ServerGameData:initData() end end end + for matchType, heroId in pairs(initHeroMap) do + self.FormationData:upHeroToFormation(GConst.BattleConst.BATTLE_TYPE.STAGE, matchType, heroId) + end end self:setNotNewPlayer() self:saveData()