Upd: [TW] rpg page definition

This commit is contained in:
LmeSzinc 2024-08-01 23:33:47 +08:00
parent debbbdae96
commit d79859e6ed
2 changed files with 22 additions and 21 deletions

View File

@ -1,6 +1,7 @@
import traceback
from module.coalition.assets import *
from module.raid.assets import *
from module.ui.assets import *
from module.ui_white.assets import *
@ -287,19 +288,19 @@ page_mail.link(button=GOTO_MAIN_WHITE, destination=page_main)
page_main_white.link(button=MAIL_ENTER_WHITE, destination=page_mail)
# RPG event (raid_20240328)
# page_rpg_stage = Page(RPG_GOTO_STORY)
# page_rpg_story = Page(RPG_GOTO_STAGE)
# page_rpg_stage.link(button=RPG_GOTO_STORY, destination=page_rpg_story)
# page_rpg_stage.link(button=RPG_HOME, destination=page_main)
# page_rpg_story.link(button=RPG_GOTO_STAGE, destination=page_rpg_stage)
# page_rpg_story.link(button=RPG_HOME, destination=page_main)
#
# page_main.link(button=MAIN_GOTO_RAID, destination=page_rpg_stage)
# # page_main_white.link(button=MAIN_GOTO_RAID_WHITE, destination=page_rpg_stage)
#
# page_rpg_city = Page(RPG_LEAVE_CITY)
# page_rpg_city.link(button=RPG_LEAVE_CITY, destination=page_rpg_stage)
# page_rpg_city.link(button=RPG_HOME, destination=page_main)
page_rpg_stage = Page(RPG_GOTO_STORY)
page_rpg_story = Page(RPG_GOTO_STAGE)
page_rpg_stage.link(button=RPG_GOTO_STORY, destination=page_rpg_story)
page_rpg_stage.link(button=RPG_HOME, destination=page_main)
page_rpg_story.link(button=RPG_GOTO_STAGE, destination=page_rpg_stage)
page_rpg_story.link(button=RPG_HOME, destination=page_main)
page_main.link(button=MAIN_GOTO_RAID, destination=page_rpg_stage)
# page_main_white.link(button=MAIN_GOTO_RAID_WHITE, destination=page_rpg_stage)
page_rpg_city = Page(RPG_LEAVE_CITY)
page_rpg_city.link(button=RPG_LEAVE_CITY, destination=page_rpg_stage)
page_rpg_city.link(button=RPG_HOME, destination=page_main)
# Keep page_rpg_stage, so Raid can import
page_rpg_stage = page_raid
# page_rpg_stage = page_raid

View File

@ -199,9 +199,9 @@ class UI(InfoHandler):
if self.appear_then_click(GOTO_MAIN_WHITE, offset=(30, 30), interval=2):
timeout.reset()
continue
# if self.appear_then_click(RPG_HOME, offset=(30, 30), interval=2):
# timeout.reset()
# continue
if self.appear_then_click(RPG_HOME, offset=(30, 30), interval=2):
timeout.reset()
continue
if self.ui_additional():
timeout.reset()
continue
@ -535,8 +535,8 @@ class UI(InfoHandler):
return True
# RPG event (raid_20240328)
# if self.appear_then_click(RPG_STATUS_POPUP, offset=(30, 30), interval=3):
# return True
if self.appear_then_click(RPG_STATUS_POPUP, offset=(30, 30), interval=3):
return True
# Idle page
if self.get_interval_timer(IDLE, interval=3).reached():
@ -573,5 +573,5 @@ class UI(InfoHandler):
self.interval_reset(RAID_CHECK)
if button == SHOP_GOTO_SUPPLY_PACK:
self.interval_reset(EXCHANGE_CHECK)
# if button in [RPG_GOTO_STAGE, RPG_GOTO_STORY, RPG_LEAVE_CITY]:
# self.interval_timer[GET_SHIP.name] = Timer(5).reset()
if button in [RPG_GOTO_STAGE, RPG_GOTO_STORY, RPG_LEAVE_CITY]:
self.interval_timer[GET_SHIP.name] = Timer(5).reset()