Skip to content

Commit

Permalink
Update screenPath.py
Browse files Browse the repository at this point in the history
  • Loading branch information
JabLuszko committed Aug 22, 2024
1 parent c00f95f commit 0a678ca
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions mapadroid/ocr/screenPath.py
Original file line number Diff line number Diff line change
Expand Up @@ -277,6 +277,9 @@ async def __handle_screentype(self, screentype: ScreenType,
screentype = await self.__handle_adventure_sync_screen(screentype)
elif screentype == ScreenType.WILLOWGO:
screentype = await self.__handle_tutorial_end()
elif screentype == ScreenType.HARDWARE_UNITY_UNSUPPORTED:
logger.warning('Detected unsupported hardware screen, PD could not handle that?')
screentype = await self.__handle_hardware_unsupported_unity_screen(diff, global_dict)
elif screentype == ScreenType.SN:
self._nextscreen = ScreenType.UNDEFINED
elif screentype == ScreenType.UPDATE:
Expand Down Expand Up @@ -1014,6 +1017,11 @@ async def __handle_login_timeout(self, diff, global_dict) -> None:
self._nextscreen = ScreenType.UNDEFINED
click_text = 'SIGNOUT,SIGN,ABMELDEN,_DECONNECTER'
await self.__click_center_button_text(click_text, diff, global_dict)

async def __handle_hardware_unsupported_unity_screen(self, diff, global_dict) -> None:
self._nextscreen = ScreenType.UNDEFINED
click_text = 'CONTINUE' # no idea if this gets translated to different lang?
await self.__click_center_button_text(click_text, diff, global_dict)

async def _take_and_analyze_screenshot(self, delay_after=0.0, delay_before=0.0, errorscreen: bool = False) -> \
Optional[Tuple[ScreenType,
Expand Down

0 comments on commit 0a678ca

Please sign in to comment.