选关前等到画面稳定再开始识别
This commit is contained in:
parent
19b5f961f5
commit
8be4f09b1d
1 changed files with 2 additions and 7 deletions
|
@ -568,6 +568,8 @@ class NavigationSolver(SceneGraphSolver):
|
|||
if self.prefix in ["PR"]:
|
||||
self.swipe_noinertia((900, 500), (-600, 0))
|
||||
elif scene == Scene.OPERATOR_CHOOSE_LEVEL:
|
||||
if self.animation():
|
||||
return
|
||||
if (
|
||||
self.mode == "copy"
|
||||
and (result := config.recog.match("story_stage"))
|
||||
|
@ -575,13 +577,6 @@ class NavigationSolver(SceneGraphSolver):
|
|||
):
|
||||
self.ctap(result[1])
|
||||
return
|
||||
|
||||
non_black_count = cv2.countNonZero(thres2(config.recog.gray, 10))
|
||||
non_black_ratio = non_black_count / (1920 * 1080)
|
||||
logger.debug(f"{non_black_ratio=}")
|
||||
if non_black_ratio < 0.1:
|
||||
self.sleep()
|
||||
return
|
||||
name, val, loc = "", 1, None
|
||||
prefix = self.prefix
|
||||
# 资源收集关直接按坐标点击
|
||||
|
|
Loading…
Add table
Reference in a new issue