From 6e2961fa5b0143a0ad369059b7e83652f781fb99 Mon Sep 17 00:00:00 2001 From: liuzujun <307836273@qq.com> Date: Mon, 25 Jan 2021 20:33:06 +0800 Subject: [PATCH] 获得所有SSR 且满级 满觉醒 同时获得全部满级金色铭文 满精进 --- src/actions/GmAction.lua | 33 ++++++++++++++++++++++++++++++++- src/csvdata | 2 +- 2 files changed, 33 insertions(+), 2 deletions(-) diff --git a/src/actions/GmAction.lua b/src/actions/GmAction.lua index 49a79c4..48fd180 100644 --- a/src/actions/GmAction.lua +++ b/src/actions/GmAction.lua @@ -247,6 +247,7 @@ table.insert(helpDes, {"获得所有零件", "get", "RUNE"}) table.insert(helpDes, {"获得所有碎片", "get", "FRAG"}) table.insert(helpDes, {"获得所有食物", "get", "FOOD"}) table.insert(helpDes, {"获得所有角色", "get", "HERO"}) +table.insert(helpDes, {"获得满级满觉醒角色,满级满精进铭文", "get", "MAXHERO"}) function _M.get(role, pms) if pms.pm1 == "ALL" then local reward = {} @@ -263,7 +264,7 @@ function _M.get(role, pms) end end elseif pms.pm1 == "RUNE" then - for itemId = 2000 , 3000 do + for itemId = 10000 , 20000 do if csvdb["itemCsv"][itemId] then role:award({[itemId] = 1}, {log = {desc = "gm"}}) end @@ -286,6 +287,36 @@ function _M.get(role, pms) role:award({[itemId] = 1}, {log = {desc = "gm"}}) end end + elseif pms.pm1 == "MAXHERO" then + -- 给英雄 + for itemId = 400 , 700 do + if csvdb["itemCsv"][itemId] then + role:award({[itemId] = 1}, {log = {desc = "gm"}}) + end + end + -- 升满级 + for _, hero in ipairs(role.heros) do + hero:updateProperty({field = "level", value = 140}) + hero:updateProperty({field = "wakeL", value = #csvdb["unit_wakeCsv"]}) + end + + -- 添加铭文 + for itemId = 10000 , 20000 do + if csvdb["itemCsv"][itemId] then + role:award({[itemId] = 1}, {log = {desc = "gm"}}) + end + end + for _, rune in ipairs(role.runeBag) do + local typ = rune:getProperty("type") + local id = rune:getProperty("id") + + local runeSet = csvdb["runeCsv"][typ] + if not runeSet then break end + local runeData = runeSet[id] + if not runeData then break end + + rune:updateProperty({field = "level",value = runeData.lvLimit}) + end else local itemId = tonum(pms.pm1) if not csvdb["itemCsv"][itemId] then diff --git a/src/csvdata b/src/csvdata index 76b7ed2..4892acb 160000 --- a/src/csvdata +++ b/src/csvdata @@ -1 +1 @@ -Subproject commit 76b7ed2b1684a9741a5c531e616acc31c8b5aa9d +Subproject commit 4892acbab51c65657ec9f02ccf661249d63e7188 -- libgit2 0.21.2