Skip to content

Commit 5a61b89

Browse files
authored
Fix fleet handling and connect activity graphs (#362)
2 parents cd8dd02 + 6e35f1a commit 5a61b89

5 files changed

Lines changed: 16 additions & 5 deletions

File tree

campaign/war_archives_20240725_cn/campaign_base.py

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,12 @@
44
class CampaignBase(CampaignBase_):
55
def campaign_set_chapter_event(self, chapter, mode='normal'):
66
self.ui_goto_sp()
7+
if chapter in ['a', 'b', 'as', 'bs', 't', 'ts', 'tss']:
8+
self.campaign_ensure_mode('normal')
9+
elif chapter in ['c', 'd', 'cs', 'ds', 'ht', 'hts']:
10+
self.campaign_ensure_mode('hard')
11+
elif chapter == 'ex_sp':
12+
self.campaign_ensure_mode('ex')
713
self.campaign_ensure_chapter(chapter)
814
return True
915

@@ -18,4 +24,6 @@ def campaign_ensure_mode(self, mode='normal'):
1824
if mode == 'hard':
1925
self.config.override(Campaign_Mode='hard')
2026

21-
self.campaign_ensure_mode_20241219(mode)
27+
# this event only have chapter T/HT and chapter SP, and war archive does not have SP
28+
# so there is no mode switch buttons
29+
# self.campaign_ensure_mode_20241219(mode)

module/config/config_manual.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ def SCHEDULER_PRIORITY(self) -> str:
200200
MAP_CHAPTER_SWITCH_20260326 = False
201201
# Since event_20241219_cn chapter B unlocks event startup
202202
# which means chapter AB are continuous
203-
STAGE_INCREASE_AB = False
203+
STAGE_INCREASE_AB = True
204204
# Insert anything to STAGE_INCREASE
205205
STAGE_INCREASE_CUSTOM = ''
206206
MAP_HAS_CLEAR_PERCENTAGE = True

module/handler/enemy_searching.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,10 @@ def handle_in_map_with_enemy_searching(self, drop=None):
121121
# 关卡可能已经结束,尽管此处预期出现敌人搜索动画
122122
if self.handle_in_stage():
123123
return True
124+
# immediately enter submarine combat in W16
125+
if hasattr(self, 'is_combat_loading') and self.is_combat_loading():
126+
logger.warning('Entered map with is_combat_loading appeared')
127+
break
124128
if self.handle_auto_search_exit(drop=drop):
125129
timeout.limit = 10
126130
timeout.reset()

module/handler/fast_forward.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -448,8 +448,7 @@ def campaign_name_increase(self, name):
448448
# 插入自定义推进逻辑
449449
if self.config.STAGE_INCREASE_AB:
450450
stage_increase = [
451-
'A1 > A2 > A3 > B1 > B2 > B3',
452-
'C1 > C2 > C3 > D1 > D2 > D3',
451+
'A1 > A2 > A3 > B1 > B2 > B3',
453452
] + stage_increase
454453
custom = self.config.STAGE_INCREASE_CUSTOM
455454
if custom:

module/map/fleet.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ def fleet_ensure(self, index):
102102
self.show_fleet()
103103
self.hp_get()
104104
self.lv_get()
105-
self.handle_strategy(index=self.fleet_current_index)
105+
self.handle_strategy(index=self.fleet_show_index)
106106
return True
107107
else:
108108
return False

0 commit comments

Comments
 (0)