Skip to content

Commit b5cee3e

Browse files
authored
refactor: ParametricTrans/自动参量质变仪js info与变量名更新 (#2224)
* fix typo: 自动参量质变仪现在可以不放薄荷了, 把提示中"薄荷"改为"材料" * 把注释和变量里面的薄荷/BH修复成了材料/MATERIAL
1 parent 6260ffa commit b5cee3e

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

repo/js/ParametricTrans/main.js

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
(async function () {
22

33
//初始化配置======================================================================================
4-
var BH = typeof settings.BH === 'string' && settings.BH.trim() !== '' ? settings.BH : "assets/bh.png";
4+
var MATERIAL = typeof settings.MATERIAL === 'string' && settings.MATERIAL.trim() !== '' ? settings.MATERIAL : "assets/bh.png";
55
var ZHIBIANYI = typeof settings.ZHIBIANY === 'string' && settings.ZHIBIANYI.trim() !== '' ? settings.ZHIBIANYI : "assets/zhibian.png";
66
var actiontime = settings.actiontime != undefined && ~~settings.actiontime > 0 ? ~~settings.actiontime : 50;
77
var CHA = "assets/cha.png"
@@ -126,7 +126,7 @@ async function deployTransformer(){
126126

127127

128128
/**======================================================================================
129-
* 游戏内“参量质变仪”的放入薄荷交互流程
129+
* 游戏内“参量质变仪”的放入材料交互流程
130130
*/
131131
async function insertMaterial(){
132132

@@ -165,12 +165,12 @@ async function insertMaterial(){
165165
await leftButtonDown();
166166
await sleep(100);
167167
await moveMouseTo(1287,161);
168-
// 薄荷图片检测
168+
// 质变材料图片检测
169169
let YOffset = 0; // Y轴偏移量,根据需要调整
170170
const maxRetries = 20; // 最大重试次数
171171
let retries = 0; // 当前重试次数
172172
while (retries < maxRetries) {
173-
await imageRecognition(BH, 1, 0, 0);
173+
await imageRecognition(MATERIAL, 1, 0, 0);
174174
if (result.found) {
175175
await leftButtonUp();
176176
await sleep(500);
@@ -245,12 +245,12 @@ async function executeAttack(){
245245
//开始执行质变仪流程============================================
246246
try {
247247
if ((await deployTransformer())) {//部署质变仪流程
248-
log.info("部署成功,准备放入薄荷!!");
248+
log.info("部署成功,准备放入材料(默认薄荷)!!");
249249
}
250-
if ((!await insertMaterial())) {//放入薄荷并开始质变流程
250+
if ((!await insertMaterial())) {//放入材料并开始质变流程
251251
log.info("未找到布置的质变仪,可能已经放入材料,尝试进行攻击流程!!");
252252
}else{
253-
log.info("放入薄荷完成,开始质变!!");
253+
log.info("放入材料完成,开始质变!!");
254254
}
255255
if ((await executeAttack())) {//芭芭拉攻击指令流程
256256
log.info("质变执行完成,结束!!");

repo/js/ParametricTrans/settings.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"label": "必填!!队伍名称,4号位放芭芭拉!"
66
},
77
{
8-
"name": "BH",
8+
"name": "MATERIAL",
99
"type": "input-text",
1010
"label": "选填,默认薄荷,识别物料的图片路径(默认assets/bh.png)",
1111
"default": "assets/bh.png"

0 commit comments

Comments
 (0)