Fix: Select team characters in forgotten hall

This commit is contained in:
LmeSzinc 2023-12-27 21:40:38 +08:00
parent 696a04e9ac
commit 6fe3c28fca
20 changed files with 80 additions and 60 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 28 KiB

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.5 KiB

After

Width:  |  Height:  |  Size: 9.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 29 KiB

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.5 KiB

After

Width:  |  Height:  |  Size: 9.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 28 KiB

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.6 KiB

After

Width:  |  Height:  |  Size: 9.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 28 KiB

After

Width:  |  Height:  |  Size: 29 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.6 KiB

After

Width:  |  Height:  |  Size: 9.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.4 KiB

After

Width:  |  Height:  |  Size: 9.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.8 KiB

After

Width:  |  Height:  |  Size: 5.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.8 KiB

After

Width:  |  Height:  |  Size: 5.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.8 KiB

After

Width:  |  Height:  |  Size: 5.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.8 KiB

After

Width:  |  Height:  |  Size: 5.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.8 KiB

After

Width:  |  Height:  |  Size: 5.9 KiB

View File

@ -7,39 +7,39 @@ CHARACTER_1 = ButtonWrapper(
name='CHARACTER_1',
share=Button(
file='./assets/share/forgotten_hall/team/CHARACTER_1.png',
area=(44, 172, 140, 196),
search=(24, 152, 160, 216),
color=(211, 210, 213),
button=(44, 106, 140, 217),
area=(32, 190, 128, 214),
search=(12, 170, 148, 234),
color=(212, 212, 210),
button=(32, 124, 128, 236),
),
)
CHARACTER_2 = ButtonWrapper(
name='CHARACTER_2',
share=Button(
file='./assets/share/forgotten_hall/team/CHARACTER_2.png',
area=(150, 172, 246, 196),
search=(130, 152, 266, 216),
color=(212, 211, 210),
button=(150, 106, 246, 218),
area=(144, 190, 240, 214),
search=(124, 170, 260, 234),
color=(216, 213, 214),
button=(144, 124, 240, 236),
),
)
CHARACTER_3 = ButtonWrapper(
name='CHARACTER_3',
share=Button(
file='./assets/share/forgotten_hall/team/CHARACTER_3.png',
area=(256, 172, 352, 196),
search=(236, 152, 372, 216),
color=(214, 211, 212),
button=(256, 106, 352, 218),
area=(256, 190, 352, 214),
search=(236, 170, 372, 234),
color=(212, 211, 214),
button=(256, 124, 352, 236),
),
)
CHARACTER_4 = ButtonWrapper(
name='CHARACTER_4',
share=Button(
file='./assets/share/forgotten_hall/team/CHARACTER_4.png',
area=(44, 304, 140, 328),
search=(24, 284, 160, 348),
color=(212, 211, 213),
button=(44, 238, 140, 350),
area=(32, 322, 128, 346),
search=(12, 302, 148, 366),
color=(213, 212, 211),
button=(32, 256, 128, 368),
),
)

View File

@ -17,51 +17,69 @@ EFFECT_NOTIFICATION = ButtonWrapper(
name='EFFECT_NOTIFICATION',
share=Button(
file='./assets/share/forgotten_hall/ui/EFFECT_NOTIFICATION.png',
area=(237, 302, 315, 380),
search=(217, 282, 335, 400),
color=(128, 114, 85),
button=(237, 302, 315, 380),
area=(250, 330, 320, 388),
search=(230, 310, 340, 408),
color=(166, 147, 108),
button=(250, 330, 320, 388),
),
)
ENTER_FORGOTTEN_HALL_DUNGEON = ButtonWrapper(
name='ENTER_FORGOTTEN_HALL_DUNGEON',
share=Button(
file='./assets/share/forgotten_hall/ui/ENTER_FORGOTTEN_HALL_DUNGEON.png',
area=(989, 649, 1231, 684),
search=(969, 629, 1251, 704),
color=(214, 214, 217),
button=(989, 649, 1231, 684),
area=(953, 640, 1225, 676),
search=(933, 620, 1245, 696),
color=(217, 217, 219),
button=(953, 640, 1225, 676),
),
)
ENTRANCE_CHECKED = ButtonWrapper(
name='ENTRANCE_CHECKED',
share=Button(
file='./assets/share/forgotten_hall/ui/ENTRANCE_CHECKED.png',
area=(55, 632, 71, 650),
search=(35, 612, 91, 670),
color=(156, 156, 157),
button=(55, 632, 71, 650),
area=(44, 655, 60, 673),
search=(24, 635, 80, 693),
color=(156, 156, 158),
button=(44, 655, 60, 673),
),
)
LAST_VASTIGES_CHECK = ButtonWrapper(
name='LAST_VASTIGES_CHECK',
share=Button(
file='./assets/share/forgotten_hall/ui/LAST_VASTIGES_CHECK.png',
area=(25, 190, 96, 262),
search=(11, 73, 111, 461),
color=(94, 126, 162),
button=(25, 190, 96, 262),
),
share=[
Button(
file='./assets/share/forgotten_hall/ui/LAST_VASTIGES_CHECK.png',
area=(25, 190, 96, 262),
search=(11, 73, 111, 461),
color=(94, 126, 162),
button=(25, 190, 96, 262),
),
Button(
file='./assets/share/forgotten_hall/ui/LAST_VASTIGES_CHECK.2.png',
area=(46, 274, 98, 348),
search=(11, 73, 111, 461),
color=(38, 53, 71),
button=(46, 274, 98, 348),
),
],
)
LAST_VASTIGES_CLICK = ButtonWrapper(
name='LAST_VASTIGES_CLICK',
share=Button(
file='./assets/share/forgotten_hall/ui/LAST_VASTIGES_CLICK.png',
area=(32, 196, 90, 254),
search=(11, 73, 111, 461),
color=(49, 64, 87),
button=(32, 196, 90, 254),
),
share=[
Button(
file='./assets/share/forgotten_hall/ui/LAST_VASTIGES_CLICK.png',
area=(32, 196, 90, 254),
search=(11, 73, 111, 461),
color=(49, 64, 87),
button=(32, 196, 90, 254),
),
Button(
file='./assets/share/forgotten_hall/ui/LAST_VASTIGES_CLICK.2.png',
area=(51, 281, 90, 341),
search=(11, 73, 111, 461),
color=(22, 29, 39),
button=(51, 281, 90, 341),
),
],
)
MEMORY_OF_CHAOS_CHECK = ButtonWrapper(
name='MEMORY_OF_CHAOS_CHECK',
@ -97,40 +115,40 @@ SEAT_1 = ButtonWrapper(
name='SEAT_1',
share=Button(
file='./assets/share/forgotten_hall/ui/SEAT_1.png',
area=(946, 518, 953, 533),
search=(926, 498, 973, 553),
color=(66, 68, 89),
button=(946, 518, 953, 533),
area=(957, 549, 966, 574),
search=(937, 529, 986, 594),
color=(77, 78, 87),
button=(957, 549, 966, 574),
),
)
SEAT_2 = ButtonWrapper(
name='SEAT_2',
share=Button(
file='./assets/share/forgotten_hall/ui/SEAT_2.png',
area=(1026, 518, 1033, 533),
search=(1006, 498, 1053, 553),
color=(68, 70, 92),
button=(1026, 518, 1033, 533),
area=(1034, 549, 1043, 574),
search=(1014, 529, 1063, 594),
color=(77, 77, 86),
button=(1034, 549, 1043, 574),
),
)
SEAT_3 = ButtonWrapper(
name='SEAT_3',
share=Button(
file='./assets/share/forgotten_hall/ui/SEAT_3.png',
area=(1106, 518, 1113, 532),
search=(1086, 498, 1133, 552),
color=(67, 69, 87),
button=(1106, 518, 1113, 532),
area=(1111, 549, 1120, 574),
search=(1091, 529, 1140, 594),
color=(76, 77, 85),
button=(1111, 549, 1120, 574),
),
)
SEAT_4 = ButtonWrapper(
name='SEAT_4',
share=Button(
file='./assets/share/forgotten_hall/ui/SEAT_4.png',
area=(1186, 518, 1193, 532),
search=(1166, 498, 1213, 552),
color=(67, 69, 86),
button=(1186, 518, 1193, 532),
area=(1188, 549, 1197, 574),
search=(1168, 529, 1217, 594),
color=(76, 77, 85),
button=(1188, 549, 1197, 574),
),
)
TELEPORT = ButtonWrapper(

View File

@ -97,10 +97,11 @@ class DraggableStageList(DraggableList):
return main.appear(ENTRANCE_CHECKED)
def load_rows(self, main: ModuleBase):
if not main.appear(FORGOTTEN_HALL_CHECK):
if main.appear(MEMORY_OF_CHAOS_CHECK) or main.appear(LAST_VASTIGES_CHECK):
return super().load_rows(main=main)
else:
logger.info('Not in forgotten hall, skip load_rows()')
return
return super().load_rows(main=main)
STAGE_LIST = DraggableStageList("ForgottenHallStageList", keyword_class=ForgottenHallStage,
@ -188,6 +189,7 @@ class ForgottenHallUI(DungeonUI, ForgottenHallTeam):
self._dungeon_nav_goto(dungeon)
self.stage_choose(dungeon)
logger.info(f'Stage list select: {stage_keyword}')
STAGE_LIST.select_row(stage_keyword, main=self)
def exit_dungeon(self, skip_first_screenshot=True):