Skip to content

Commit

Permalink
Update screenPath.py
Browse files Browse the repository at this point in the history
  • Loading branch information
JabLuszko authored Sep 2, 2023
1 parent 3cd23de commit de6c3ee
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions mapadroid/ocr/screenPath.py
Original file line number Diff line number Diff line change
Expand Up @@ -267,8 +267,6 @@ async def __handle_screentype(self, screentype: ScreenType,
if MadGlobals.application_args.enable_early_maintenance_detection and self._worker_state.maintenance_early_detection_triggered:
logger.warning("Seen RETRY screen after multiple proto timeouts - most likely MAINTENANCE")
await self._account_handler.mark_burnt(self._worker_state.device_id, BurnType.MAINTENANCE)
# forcing clear_game_data here due to Niantic changes and game now remembering/pre-filling username on login
await self.clear_game_data()
await self.__handle_retry_screen(diff, global_dict)
elif screentype == ScreenType.WRONG:
await self.__handle_returning_player_or_wrong_credentials()
Expand Down Expand Up @@ -425,8 +423,12 @@ async def __handle_google_login(self, screentype) -> ScreenType:

async def __handle_retry_screen(self, diff, global_dict) -> None:
self._nextscreen = ScreenType.UNDEFINED
click_text = 'DIFFERENT,AUTRE,AUTORISER,ANDERES,KONTO,ACCOUNT'
await self.__click_center_button_text(click_text, diff, global_dict)
# forcing clear_game_data here due to Niantic changes and game now remembering/pre-filling username on login
await self.clear_game_data()
# after clear_game_data there should be no reason to click this button as game gets killed
# but let's leave it here if Niantic decides this is a bug rather than QOL change
#click_text = 'DIFFERENT,AUTRE,AUTORISER,ANDERES,KONTO,ACCOUNT'
#await self.__click_center_button_text(click_text, diff, global_dict)

async def __click_center_button_text(self, click_text, diff, global_dict):
n_boxes = len(global_dict['text'])
Expand Down

0 comments on commit de6c3ee

Please sign in to comment.