From 813a107c0229fba92e1cd349426a00699ee01297 Mon Sep 17 00:00:00 2001 From: yan Date: Fri, 27 Feb 2026 20:34:44 +0800 Subject: [PATCH] =?UTF-8?q?fix(AutoPlan):=20=E4=BF=AE=E5=A4=8D=E5=9C=B0?= =?UTF-8?q?=E8=84=89=E5=BC=82=E5=B8=B8=E5=A4=84=E7=90=86=E9=80=BB=E8=BE=91?= =?UTF-8?q?=E4=B8=AD=E7=9A=84=E6=97=A0=E9=99=90=E5=BE=AA=E7=8E=AF=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 调整了 ESCAPE 键按压和睡眠操作的位置以避免重复执行 - 确保在主界面检测成功时能够正确跳出循环 - 保持原有的重试机制和错误处理逻辑不变 --- repo/js/AutoPlan/utils/tool.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/repo/js/AutoPlan/utils/tool.js b/repo/js/AutoPlan/utils/tool.js index 92d6f4c02..32beb2d81 100644 --- a/repo/js/AutoPlan/utils/tool.js +++ b/repo/js/AutoPlan/utils/tool.js @@ -187,13 +187,13 @@ async function outDomainUI() { await findTextAndClick('地脉异常') await sleep(ms); while (!await isInOutDomainUI()) { - await sleep(ms); - await keyPress("ESCAPE"); - await sleep(ms * 2); if (isInMainUI()) { inMainUI = true break } + await sleep(ms); + await keyPress("ESCAPE"); + await sleep(ms * 2); if (index > 3) { log.error(`多次尝试匹配退出秘境界面失败 假定已经退出处理`); tryMax = true