From d9787357b940a5e6541cbc4a2e24666c0d2d5d5e Mon Sep 17 00:00:00 2001 From: this-Fish Date: Mon, 22 Sep 2025 20:05:05 +0800 Subject: [PATCH] =?UTF-8?q?JS=EF=BC=9A=E9=A3=9F=E6=9D=90=E5=8A=A0=E5=B7=A5?= =?UTF-8?q?(=E6=A8=A1=E6=93=AC=E9=BB=9E=E6=93=8A)=20v1.0.1=20(#1968)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 修正酸奶油參數錯誤 - 加快等待時間 - 修改腳本名字為"食材加工(模拟点击)" --- repo/js/食材加工(模拟点击)/README.md | 6 ++++++ repo/js/食材加工(模拟点击)/main.js | 26 ++++++++++++------------ repo/js/食材加工(模拟点击)/manifest.json | 4 ++-- repo/js/食材加工(模拟点击)/settings.json | 2 +- 4 files changed, 22 insertions(+), 16 deletions(-) diff --git a/repo/js/食材加工(模拟点击)/README.md b/repo/js/食材加工(模拟点击)/README.md index 3f73b0c63..b8b62f0e9 100644 --- a/repo/js/食材加工(模拟点击)/README.md +++ b/repo/js/食材加工(模拟点击)/README.md @@ -58,6 +58,12 @@ ## 📜 更新日志 +### v1.0.1 `(2025-09-22)` + +- 修正酸奶油參數錯誤 +- 加快等待時間 +- 修改腳本名字為"食材加工(模拟点击)" + ### v1.0 `(2025-09-21)` - 初始版本发布 diff --git a/repo/js/食材加工(模拟点击)/main.js b/repo/js/食材加工(模拟点击)/main.js index f43c17de0..9cb1040b2 100644 --- a/repo/js/食材加工(模拟点击)/main.js +++ b/repo/js/食材加工(模拟点击)/main.js @@ -95,20 +95,20 @@ if (quantity) { log.info(`开始加工:${key}`); click(x, y); - await sleep(1000); + await sleep(500); click(1690, 1015); // 制作 - await sleep(1000); + await sleep(500); // 输入数量 //click(965, 455); //await sleep(1000); //await inputText(quantity); //拉满 click(1190, 590); - await sleep(1000); + await sleep(500); click(1190, 755); // 确认 - await sleep(1000); + await sleep(500); } }; // 通用:模拟输入文本 @@ -244,7 +244,7 @@ // 如果未找到 Cooking 图标,执行滚轮操作 log.info(`未找到 Cooking 图标,执行滚轮操作,当前尝试次数:${scrollAttempts + 1}`); await keyMouseScript.runFile(`assets/滚轮下翻.json`); - await sleep(1000); + await sleep(800); // 重新识别 F 图标,获取最新的中心点 fRes = await recognizeFIcon(); @@ -281,15 +281,15 @@ //食材加工 click(1010, 50); //选择食材加工 - await sleep(1000); + await sleep(500); click(255, 1020); //全部领取 - await sleep(1000); + await sleep(500); click(960, 1045); //点击任意处 - await sleep(1000); + await sleep(500); click(960, 1045); //点击任意处 - await sleep(1000); + await sleep(500); click(960, 1045); //点击任意处 - await sleep(2000); + await sleep(800); // 按行列处理所有食材 for (const ingredient of ingredientCoordinates) { @@ -299,11 +299,11 @@ } await genshin.returnMainUi(); - await sleep(1000); + await sleep(800); keyDown("S"); - await sleep(1500); - keyUp("S"); await sleep(1000); + keyUp("S"); + await sleep(800); } catch (error) { log.error(`执行按键或鼠标操作时发生错误:${error.message}`); } diff --git a/repo/js/食材加工(模拟点击)/manifest.json b/repo/js/食材加工(模拟点击)/manifest.json index 6fbbe1e6c..414649822 100644 --- a/repo/js/食材加工(模拟点击)/manifest.json +++ b/repo/js/食材加工(模拟点击)/manifest.json @@ -1,7 +1,7 @@ { "manifest_version": 1, - "name": "食材加工", - "version": "1.0", + "name": "食材加工(模拟点击)", + "version": "1.0.1", "description": "根据选择加工物,自动加工食材。加工时会直接拉满加工数量。\n \n使用前请阅读“readme”文件以获取更多详细信息。", "tags": ["食材加工", "模拟点击"], diff --git a/repo/js/食材加工(模拟点击)/settings.json b/repo/js/食材加工(模拟点击)/settings.json index b70eede41..105d4c65c 100644 --- a/repo/js/食材加工(模拟点击)/settings.json +++ b/repo/js/食材加工(模拟点击)/settings.json @@ -55,7 +55,7 @@ "label": " 香辛料" }, { - "name": "smetanaNum", + "name": "smetana", "type": "checkbox", "label": " 酸奶油" },