From 1d57777b32cef479593d99d5f52481d26a189ab0 Mon Sep 17 00:00:00 2001 From: LmeSzinc <37934724+LmeSzinc@users.noreply.github.com> Date: Sun, 14 Apr 2024 23:05:35 +0800 Subject: [PATCH] Fix: Check rogue entry button available --- route/rogue/Combat/Jarilo_CorridorofFadingEchoes_F1.py | 2 +- tasks/rogue/entry/entry.py | 2 +- tasks/rogue/entry/path.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/route/rogue/Combat/Jarilo_CorridorofFadingEchoes_F1.py b/route/rogue/Combat/Jarilo_CorridorofFadingEchoes_F1.py index c2d83ca9d..004217fb9 100644 --- a/route/rogue/Combat/Jarilo_CorridorofFadingEchoes_F1.py +++ b/route/rogue/Combat/Jarilo_CorridorofFadingEchoes_F1.py @@ -168,7 +168,7 @@ class Route(RouteBase): enemy2right.straight_run(), enemy2left.straight_run().set_threshold(5), ) - if self.minimap.is_position_near(enemy2right, threshold=30): + if self.minimap.is_position_near(enemy2left.position, threshold=30): logger.info('Near enemy2right') self.clear_enemy( enemy2left.set_threshold(5), diff --git a/tasks/rogue/entry/entry.py b/tasks/rogue/entry/entry.py index c889f23b1..58dc40a66 100644 --- a/tasks/rogue/entry/entry.py +++ b/tasks/rogue/entry/entry.py @@ -249,7 +249,7 @@ class RogueEntry(RouteBase, RogueRewardHandler, RoguePathHandler, DungeonUI): self.device.click(WORLD_ENTER) self.interval_reset(REWARD_ENTER, interval=2) continue - if self.appear(LEVEL_CONFIRM, interval=2): + if self.match_template_color(LEVEL_CONFIRM, interval=2): self.dungeon_update_stamina() self.check_stop_condition() self.device.click(LEVEL_CONFIRM) diff --git a/tasks/rogue/entry/path.py b/tasks/rogue/entry/path.py index 8ab17b50b..2d3af237c 100644 --- a/tasks/rogue/entry/path.py +++ b/tasks/rogue/entry/path.py @@ -205,7 +205,7 @@ class RoguePathHandler(RogueUI): logger.info('rogue_path_select ended at page_main') break - if self.appear(ROGUE_LAUNCH, interval=2): + if self.match_template_color(ROGUE_LAUNCH, interval=2): if not self._is_team_prepared(): raise RogueTeamNotPrepared self.device.click(ROGUE_LAUNCH)