From 49d408b5d3c7ca55a34a7c7ee1625cd4cf0deba5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=A7=8B=E4=BA=91?= Date: Thu, 7 Aug 2025 23:28:34 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E6=89=8B=E5=8A=A8=E7=AE=A1=E7=90=86?= =?UTF-8?q?=E6=88=AA=E5=9B=BE=E5=86=85=E5=AD=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- repo/js/AutoFriendshipFight/main.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/repo/js/AutoFriendshipFight/main.js b/repo/js/AutoFriendshipFight/main.js index 981637ca..b921c2eb 100644 --- a/repo/js/AutoFriendshipFight/main.js +++ b/repo/js/AutoFriendshipFight/main.js @@ -105,7 +105,7 @@ async function detectTaskTrigger(ocrTimeout, enemyType) { while (Date.now() - ocrStartTime < ocrTimeout * 1000 && !ocrStatus) { let captureRegion = captureGameRegion(); let resList = captureRegion.findMulti(RecognitionObject.ocr(0, 200, 300, 300)); - + captureRegion.dispose(); for (let o = 0; o < resList.count; o++) { let res = resList[o]; for (let keyword of ocrKeywords) { @@ -474,7 +474,7 @@ async function waitForBattleResult(timeout = 2 * 60 * 1000, enemyType = "盗宝 let result2 = capture.find(RecognitionObject.ocr(0, 200, 300, 300)); let text = result.text; let text2 = result2.text; - + capture.dispose(); // 检查成功关键词 for (let keyword of successKeywords) { if (text.includes(keyword)) {