From c56d8dbf1a4a45070cd94a8965bd63dc7b190aa9 Mon Sep 17 00:00:00 2001 From: Kubbo <390378816@qq.com> Date: Mon, 13 Jan 2025 00:33:01 +0800 Subject: [PATCH] =?UTF-8?q?refactor(config):=20=E6=9B=B4=E6=96=B0=E7=89=A9?= =?UTF-8?q?=E5=93=81=E5=90=88=E6=88=90=E9=85=8D=E7=BD=AE=E5=B9=B6=E6=89=A9?= =?UTF-8?q?=E5=B1=95=20JSON=20=E8=BD=AC=E6=8D=A2=E8=84=9A=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 修改 ItemMergeConfig.json 中的 second_index 字段值 - 更新 json2lua.js 脚本,使其支持更多的 JSON 文件转换 --- configs/ItemMergeConfig.json | 2 +- json2lua.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/configs/ItemMergeConfig.json b/configs/ItemMergeConfig.json index dd91494..989904f 100644 --- a/configs/ItemMergeConfig.json +++ b/configs/ItemMergeConfig.json @@ -4134,7 +4134,7 @@ "index": 3, "text": "兑换", "Eid": 3301, - "second_index": 1, + "second_index": 3, "buttontxt10": "合成10次", "mergebutton10": 1, "table": [ diff --git a/json2lua.js b/json2lua.js index fc0ff85..558d00e 100644 --- a/json2lua.js +++ b/json2lua.js @@ -42,7 +42,7 @@ const start = () => { const files = fs.readdirSync(folderPath); // 过滤出所有的 JSON 文件 - const jsonFiles = files.filter(file => path.extname(file) === '.json').filter(file => ["StdItems","ItemMergeConfig"].map(e => `${e}.json`).includes(file)); + const jsonFiles = files.filter(file => path.extname(file) === '.json').filter(file => ["StdItems","ItemMergeConfig","MergeConfig","MergeTotal"].map(e => `${e}.json`).includes(file)); jsonFiles.forEach(file => { const json = JSON.parse(fs.readFileSync(path.join(folderPath, file), 'utf8')) const filename = path.basename(file, path.extname(file));