mirror of
https://github.com/LmeSzinc/AzurLaneAutoScript.git
synced 2025-01-07 07:26:46 +08:00
Opt: wait until navbar active is not None (#3832)
This commit is contained in:
parent
1e793295e8
commit
bb3f4964ec
@ -103,17 +103,15 @@ class GachaUI(UI):
|
||||
def _construct_bottom_navbar(self):
|
||||
"""
|
||||
limited 4 options
|
||||
build.
|
||||
limited_build.
|
||||
orders.
|
||||
shop.
|
||||
retire.
|
||||
event.
|
||||
light.
|
||||
heavy.
|
||||
special.
|
||||
|
||||
regular 3 options
|
||||
build.
|
||||
orders.
|
||||
shop.
|
||||
retire.
|
||||
light.
|
||||
heavy.
|
||||
special.
|
||||
"""
|
||||
construct_bottom_navbar = ButtonGrid(
|
||||
origin=(262, 615), delta=(209, 0),
|
||||
|
@ -188,7 +188,8 @@ class Navbar:
|
||||
active, minimum, maximum = self.get_info(main=main)
|
||||
logger.info(f'Nav item active: {active} from range ({minimum}, {maximum})')
|
||||
# Get None when receiving a pure black screenshot.
|
||||
if minimum is None or maximum is None:
|
||||
# Active is None could be because of slow animation
|
||||
if active is None or minimum is None or maximum is None:
|
||||
continue
|
||||
|
||||
index = minimum + left - 1 if left is not None else maximum - right + 1
|
||||
|
Loading…
Reference in New Issue
Block a user