Fix: Handle USER_AGREEMENT_ACCEPT at login

This commit is contained in:
LmeSzinc 2023-07-19 13:01:44 +08:00
parent c9ddacfedb
commit 4440523d67
6 changed files with 17 additions and 5 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

View File

@ -37,10 +37,10 @@ OCR_WAVE_COUNT = ButtonWrapper(
name='OCR_WAVE_COUNT',
share=Button(
file='./assets/share/combat/prepare/OCR_WAVE_COUNT.png',
area=(911, 549, 1151, 581),
search=(891, 529, 1171, 601),
color=(27, 29, 32),
button=(911, 549, 1151, 581),
area=(911, 555, 1151, 581),
search=(891, 535, 1171, 601),
color=(32, 34, 37),
button=(911, 555, 1151, 581),
),
)
WAVE_MINUS = ButtonWrapper(

View File

@ -13,3 +13,13 @@ LOGIN_CONFIRM = ButtonWrapper(
button=(683, 327, 1143, 620),
),
)
USER_AGREEMENT_ACCEPT = ButtonWrapper(
name='USER_AGREEMENT_ACCEPT',
cn=Button(
file='./assets/cn/login/USER_AGREEMENT_ACCEPT.png',
area=(751, 467, 791, 488),
search=(731, 447, 811, 508),
color=(196, 167, 111),
button=(678, 459, 867, 496),
),
)

View File

@ -2,7 +2,7 @@ from module.base.timer import Timer
from module.logger import logger
from tasks.base.page import page_main
from tasks.base.ui import UI
from tasks.login.assets.assets_login import LOGIN_CONFIRM
from tasks.login.assets.assets_login import LOGIN_CONFIRM, USER_AGREEMENT_ACCEPT
class Login(UI):
@ -38,6 +38,8 @@ class Login(UI):
# Login
if self.appear_then_click(LOGIN_CONFIRM):
continue
if self.appear_then_click(USER_AGREEMENT_ACCEPT):
continue
# Additional
if self.ui_additional():
continue