diff --git a/assets/share/dungeon/event/OCR_DOUBLE_ROGUE_REMAIN.png b/assets/share/dungeon/event/OCR_DOUBLE_ROGUE_REMAIN.png new file mode 100644 index 000000000..b103b3abe Binary files /dev/null and b/assets/share/dungeon/event/OCR_DOUBLE_ROGUE_REMAIN.png differ diff --git a/tasks/dungeon/assets/assets_dungeon_event.py b/tasks/dungeon/assets/assets_dungeon_event.py index e330b7808..5afe54516 100644 --- a/tasks/dungeon/assets/assets_dungeon_event.py +++ b/tasks/dungeon/assets/assets_dungeon_event.py @@ -53,3 +53,13 @@ OCR_DOUBLE_EVENT_REMAIN_AT_COMBAT = ButtonWrapper( button=(799, 460, 1268, 626), ), ) +OCR_DOUBLE_ROGUE_REMAIN = ButtonWrapper( + name='OCR_DOUBLE_ROGUE_REMAIN', + share=Button( + file='./assets/share/dungeon/event/OCR_DOUBLE_ROGUE_REMAIN.png', + area=(517, 179, 1118, 201), + search=(497, 159, 1138, 221), + color=(203, 145, 88), + button=(517, 179, 1118, 201), + ), +) diff --git a/tasks/dungeon/dungeon.py b/tasks/dungeon/dungeon.py index 8bf32a05b..94fb93bef 100644 --- a/tasks/dungeon/dungeon.py +++ b/tasks/dungeon/dungeon.py @@ -209,7 +209,7 @@ class Dungeon(DungeonStamina, DungeonEvent, Combat): relic = 0 rogue = 0 if self.has_double_rogue_event(): - rogue = self.get_double_event_remain() + rogue = self.get_double_rogue_remain() if self.has_double_calyx_event(): self._dungeon_nav_goto(KEYWORDS_DUNGEON_NAV.Calyx_Golden) calyx = self.get_double_event_remain() diff --git a/tasks/dungeon/event.py b/tasks/dungeon/event.py index f6edd29c1..cde2c8951 100644 --- a/tasks/dungeon/event.py +++ b/tasks/dungeon/event.py @@ -9,6 +9,7 @@ from tasks.dungeon.assets.assets_dungeon_event import ( DOUBLE_ROGUE_EVENT_TAG, OCR_DOUBLE_EVENT_REMAIN, OCR_DOUBLE_EVENT_REMAIN_AT_COMBAT, + OCR_DOUBLE_ROGUE_REMAIN, ) @@ -51,6 +52,8 @@ class DungeonEvent(UI): """ has = self.image_color_count(DOUBLE_ROGUE_EVENT_TAG, color=(252, 209, 123), threshold=221, count=50) has |= self.image_color_count(DOUBLE_ROGUE_EVENT_TAG, color=(252, 251, 140), threshold=221, count=50) + # Anniversary 3x rogue event + has |= self.image_color_count(DOUBLE_ROGUE_EVENT_TAG, color=(229, 62, 44), threshold=221, count=50) logger.attr('Double rogue', has) return has @@ -84,6 +87,15 @@ class DungeonEvent(UI): logger.attr('Double event remain', remain) return remain + def get_double_rogue_remain(self) -> int: + """ + Pages: + in: page_guide, Survival_Index, selected at the nav with double event + """ + remain = self._get_double_event_remain(OCR_DOUBLE_ROGUE_REMAIN) + logger.attr('Double event remain', remain) + return remain + def get_double_event_remain_at_combat(self) -> int | None: """ Pages: