Skip to content

Commit

Permalink
启动游戏时检查MowerExit
Browse files Browse the repository at this point in the history
  • Loading branch information
ZhaoZuohong committed Jul 19, 2024
1 parent 68303a7 commit cc0078c
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions arknights_mower/utils/device/device.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@

import gzip
import subprocess
import time
from typing import Optional

import cv2
import numpy as np

from arknights_mower import __rootdir__, __system__
from arknights_mower.utils import config
from arknights_mower.utils.csleep import csleep
from arknights_mower.utils.device.adb_client.core import Client as ADBClient
from arknights_mower.utils.device.adb_client.session import Session
from arknights_mower.utils.device.maatouch import MaaTouch
Expand Down Expand Up @@ -320,8 +320,7 @@ def check_current_focus(self) -> bool:
]:
self.exit() # 防止应用卡死
self.launch()
# wait for app to finish launching
time.sleep(10)
csleep(10)
update = True
return update
except Exception:
Expand Down

0 comments on commit cc0078c

Please sign in to comment.