1
0
mirror of https://gitee.com/sui-feng-cb/AzurLaneAutoScript1 synced 2026-03-17 04:05:36 +08:00

Merge pull request #2495 from LmeSzinc/dev

Bug fix
This commit is contained in:
LmeSzinc
2023-04-15 00:16:36 +08:00
committed by GitHub
4 changed files with 29 additions and 16 deletions

View File

@@ -160,12 +160,19 @@ class ActionPointHandler(UI, MapEventHandler):
# Having too many current AP, probably an OCR error
if self._action_point_current > 600:
continue
oil, boxes = self._action_point_box[0], self._action_point_box[1:]
# Having boxes
if sum(self._action_point_box[1:]) > 0:
break
if sum(boxes) > 0:
if oil > 100:
break
else:
# [11, 0, 1, 0]
continue
# Or having oil
# Might be 0 or 1 when page is not fully loaded
if self._action_point_box[0] > 100:
# [1, 0, 0, 0]
if oil > 100:
break
@staticmethod

View File

@@ -558,6 +558,8 @@ class UI(InfoHandler):
# Login
if self.appear_then_click(LOGIN_CHECK, offset=(30, 30), interval=3):
return True
if self.appear_then_click(LOGIN_ANNOUNCE, offset=(30, 30), interval=3):
return True
# Mistaken click
if self.appear(EXERCISE_PREPARATION, interval=3):