mirror of
https://gitee.com/sui-feng-cb/AzurLaneAutoScript1
synced 2026-03-24 11:19:03 +08:00
Fix: Entered wrong sub-page in meowfficer (fixed #1513)
This commit is contained in:
@@ -21,6 +21,38 @@ class MeowfficerBase(UI):
|
||||
|
||||
return False
|
||||
|
||||
def meow_enter(self, click_button, check_button, skip_first_screenshot=True):
|
||||
"""
|
||||
Enters sub-page, handle MEOWFFICER_INFO and mistaken clicks
|
||||
|
||||
Pages:
|
||||
in: page_meowfficer
|
||||
out: check_button
|
||||
"""
|
||||
accident_page = [MEOWFFICER_TRAIN_START, MEOWFFICER_BUY, MEOWFFICER_FORT_CHECK]
|
||||
accident_page = [page for page in accident_page if page != check_button]
|
||||
while 1:
|
||||
if skip_first_screenshot:
|
||||
skip_first_screenshot = False
|
||||
else:
|
||||
self.device.screenshot()
|
||||
|
||||
self.appear_then_click(MEOWFFICER_TRAIN_ENTER, offset=(20, 20), interval=5)
|
||||
# End
|
||||
if self.appear(check_button, offset=(20, 20)):
|
||||
break
|
||||
# Click
|
||||
if self.appear_then_click(click_button, offset=(20, 20), interval=3):
|
||||
continue
|
||||
# Accident click
|
||||
if self.meow_additional():
|
||||
continue
|
||||
for button in accident_page:
|
||||
if self.appear(button, offset=(20, 20), interval=3):
|
||||
self.device.click(MEOWFFICER_CHECK)
|
||||
self.interval_clear(click_button)
|
||||
break
|
||||
|
||||
def meow_menu_close(self, skip_first_screenshot=True):
|
||||
"""
|
||||
Exit from any meowfficer menu popups
|
||||
|
||||
Reference in New Issue
Block a user