Fix: Check rogue entry button available

This commit is contained in:
LmeSzinc 2024-04-14 23:05:35 +08:00
parent a12763b94b
commit 1d57777b32
3 changed files with 3 additions and 3 deletions

View File

@ -168,7 +168,7 @@ class Route(RouteBase):
enemy2right.straight_run(), enemy2right.straight_run(),
enemy2left.straight_run().set_threshold(5), 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') logger.info('Near enemy2right')
self.clear_enemy( self.clear_enemy(
enemy2left.set_threshold(5), enemy2left.set_threshold(5),

View File

@ -249,7 +249,7 @@ class RogueEntry(RouteBase, RogueRewardHandler, RoguePathHandler, DungeonUI):
self.device.click(WORLD_ENTER) self.device.click(WORLD_ENTER)
self.interval_reset(REWARD_ENTER, interval=2) self.interval_reset(REWARD_ENTER, interval=2)
continue continue
if self.appear(LEVEL_CONFIRM, interval=2): if self.match_template_color(LEVEL_CONFIRM, interval=2):
self.dungeon_update_stamina() self.dungeon_update_stamina()
self.check_stop_condition() self.check_stop_condition()
self.device.click(LEVEL_CONFIRM) self.device.click(LEVEL_CONFIRM)

View File

@ -205,7 +205,7 @@ class RoguePathHandler(RogueUI):
logger.info('rogue_path_select ended at page_main') logger.info('rogue_path_select ended at page_main')
break break
if self.appear(ROGUE_LAUNCH, interval=2): if self.match_template_color(ROGUE_LAUNCH, interval=2):
if not self._is_team_prepared(): if not self._is_team_prepared():
raise RogueTeamNotPrepared raise RogueTeamNotPrepared
self.device.click(ROGUE_LAUNCH) self.device.click(ROGUE_LAUNCH)