js:狗粮团购1.10.2 (#2521)

更新强迫症模式
This commit is contained in:
mno
2025-12-18 15:55:03 +08:00
committed by GitHub
parent 4c85ee7273
commit 572c84a5b9
3 changed files with 16 additions and 7 deletions

View File

@@ -142,9 +142,18 @@ let skipRunning = false;
if (skipRunning) {
log.info(`本次运行启用并触发了强迫症模式,需要重新上线`);
log.debug('ABGI启动联机上线');
await sleep(2000);
log.debug('ABGI启动配置组强迫症等待组');
// 按中文分号分割字符串
const segments = settings.onlyRunPerfectly.split('');
// 逐段输出每段间隔1秒
for (const segment of segments) {
if (segment.trim()) { // 跳过空段落
log.info(segment.trim());
await sleep(1000);
}
}
return;
}
@@ -338,7 +347,7 @@ async function runGroupPurchasing(runExtra) {
}
log.warn("等待队友就绪超时");
if (settings.onlyRunPerfectly === "确认启用强迫症模式") {
if (settings.onlyRunPerfectly) {
skipRunning = true;
doRunExtra = false;
}
@@ -770,7 +779,7 @@ async function autoEnter(autoEnterSettings) {
if (new Date() - start >= timeout * 60 * 1000) {
log.warn("超时未达到预定人数");
notification.error(`超时未达到预定人数`);
if (settings.onlyRunPerfectly === "确认启用强迫症模式") {
if (settings.onlyRunPerfectly) {
skipRunning = true;
doRunExtra = false;
}

View File

@@ -1,7 +1,7 @@
{
"manifest_version": 1,
"name": "AAA狗粮联机团购",
"version": "1.10.1",
"version": "1.10.2",
"tags": [
"狗粮"
],

View File

@@ -17,7 +17,7 @@
{
"name": "onlyRunPerfectly",
"type": "input-text",
"label": "输入:\n确认启用强迫症模式\n以启用\n人不齐或队友未正常到位时不执行任何路线"
"label": "输入任意内容后启用强迫症模式\n人不齐或队友未正常到位时不执行任何路线\n并在运行结束后输出按中文分号分隔的内容"
},
{
"name": "groupMode",