diff --git a/assets/cn/war_archives/TEMPLATE_ANTHEM_OF_REMEMBRANCE.png b/assets/cn/war_archives/TEMPLATE_ANTHEM_OF_REMEMBRANCE.png new file mode 100644 index 000000000..1a004fcc1 Binary files /dev/null and b/assets/cn/war_archives/TEMPLATE_ANTHEM_OF_REMEMBRANCE.png differ diff --git a/assets/cn/war_archives/TEMPLATE_OPERATION_CONVERGENCE.png b/assets/cn/war_archives/TEMPLATE_OPERATION_CONVERGENCE.png new file mode 100644 index 000000000..cf1d6f020 Binary files /dev/null and b/assets/cn/war_archives/TEMPLATE_OPERATION_CONVERGENCE.png differ diff --git a/campaign/Readme.md b/campaign/Readme.md index d439ebb8b..0a518d1b2 100644 --- a/campaign/Readme.md +++ b/campaign/Readme.md @@ -58,6 +58,8 @@ To add a new event, add a new row in here, and run `python -m module.config.conf | 20251106 | war archives 20220915 cn | Violet Tempest Blooming Lycoris | 紫绛槿岚 | Violet Tempest Blooming Lycoris | 赫の涙月 菫の暁風 | 紫絳槿嵐 | | 20251218 | war archives 20221222 cn | Parallel Superimposition | 定向折叠 | Parallel Superimposition | 積重なる事象の幻界 | 定向折疊 | | 20260129 | war archives 20230223 cn | Revelations of Dust | 湮烬尘墟 | Revelations of Dust | 黙示の遺構 | 湮燼塵墟 | +| 20260409 | war archives 20220818 cn | Operation Convergence | 远汇点作战 | Operation Convergence | 結像点作戦 | 遠匯點作戰 | +| 20260507 | war archives 20230803 cn | Anthem of Remembrance | 奏响鸢尾之歌 | Anthem of Remembrance | 燃ゆる聖都の回想曲 | 奏響鳶尾之歌 | | 20200227 | event 20200227 cn | Northern Overture | 北境序曲 | Northern Overture | 凍絶の北海 | - | | 20200312 | event 20200312 cn | The Solomon Ranger | 复刻斯图尔特的硝烟 | The Solomon Ranger Rerun | 南洋に靡く硝煙(復刻) | - | | 20200326 | event 20200326 cn | Microlayer Medley | 微层混合 | Microlayer Medley | 闇靄払う銀翼 | - | diff --git a/campaign/war_archives_20220818_cn/campaign_base.py b/campaign/war_archives_20220818_cn/campaign_base.py new file mode 100644 index 000000000..ac9346e66 --- /dev/null +++ b/campaign/war_archives_20220818_cn/campaign_base.py @@ -0,0 +1,35 @@ +from ..campaign_war_archives.campaign_base import CampaignBase as CampaignBase_ + + +class CampaignBase(CampaignBase_): + def campaign_set_chapter_sp(self, chapter, mode='normal'): + # SP event but has an `event` UI + from module.logger import logger + logger.info('Set chapter SP') + if chapter in ['sp', 'sp_sp']: + self.ui_goto_sp() + self.campaign_ensure_chapter(chapter) + return True + else: + return False + + @staticmethod + def _campaign_separate_name(name): + if name in ['esp', 'sp']: + return 'sp_sp', '2' + if name in ['ex']: + return 'sp_ex', '3' + return CampaignBase_._campaign_separate_name(name) + + def campaign_get_entrance(self, name): + if name == 'sp': + name = 'esp' + return super().campaign_get_entrance(name) + + @staticmethod + def _campaign_get_chapter_index(name): + if name in ['sp_sp']: + return 2 + if name in ['sp_ex']: + return 3 + return CampaignBase_._campaign_get_chapter_index(name) \ No newline at end of file diff --git a/campaign/war_archives_20220818_cn/sp1.py b/campaign/war_archives_20220818_cn/sp1.py new file mode 100644 index 000000000..1c47df947 --- /dev/null +++ b/campaign/war_archives_20220818_cn/sp1.py @@ -0,0 +1,77 @@ +from .campaign_base import CampaignBase +from module.map.map_base import CampaignMap +from module.map.map_grids import SelectedGrids, RoadGrids +from module.logger import logger + +MAP = CampaignMap('SP1') +MAP.shape = 'I7' +MAP.camera_data = ['D4', 'E5', 'F4'] +MAP.camera_data_spawn_point = ['D3'] +MAP.map_data = """ + -- ++ -- SP -- SP -- ++ ++ + -- ++ -- -- -- -- -- ME -- + ME -- -- -- MS -- -- -- ME + -- -- Me ++ Me ++ Me -- -- + ME -- -- -- __ -- -- -- ME + -- ++ ++ ME -- ME -- ME -- + -- -- ++ -- MB -- ++ ++ ++ +""" +MAP.weight_data = """ + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 +""" +MAP.spawn_data = [ + {'battle': 0, 'enemy': 2, 'siren': 1}, + {'battle': 1, 'enemy': 2}, + {'battle': 2, 'enemy': 1}, + {'battle': 3, 'enemy': 1}, + {'battle': 4, 'boss': 1}, +] +A1, B1, C1, D1, E1, F1, G1, H1, I1, \ +A2, B2, C2, D2, E2, F2, G2, H2, I2, \ +A3, B3, C3, D3, E3, F3, G3, H3, I3, \ +A4, B4, C4, D4, E4, F4, G4, H4, I4, \ +A5, B5, C5, D5, E5, F5, G5, H5, I5, \ +A6, B6, C6, D6, E6, F6, G6, H6, I6, \ +A7, B7, C7, D7, E7, F7, G7, H7, I7, \ + = MAP.flatten() + + +class Config: + # ===== Start of generated config ===== + MAP_SIREN_TEMPLATE = ['Z46', 'PrinzHeinrich', 'GrafZeppelin'] + MOVABLE_ENEMY_TURN = (2,) + MAP_HAS_SIREN = True + MAP_HAS_MOVABLE_ENEMY = True + MAP_HAS_MAP_STORY = True + MAP_HAS_FLEET_STEP = True + MAP_HAS_AMBUSH = True + MAP_HAS_MYSTERY = False + # ===== End of generated config ===== + + HOMO_EDGE_HOUGHLINES_THRESHOLD = 210 + MAP_SWIPE_MULTIPLY = (1.203, 1.226) + MAP_SWIPE_MULTIPLY_MINITOUCH = (1.164, 1.185) + MAP_SWIPE_MULTIPLY_MAATOUCH = (1.130, 1.150) + + +class Campaign(CampaignBase): + MAP = MAP + ENEMY_FILTER = '1L > 1M > 1E > 1C > 2L > 2M > 2E > 2C > 3L > 3M > 3E > 3C' + MAP_AIR_RAID_OVERLAY_TRANSPARENCY_THRESHOLD = 0.25 + + def battle_0(self): + if self.clear_siren(): + return True + if self.clear_filter_enemy(self.ENEMY_FILTER, preserve=0): + return True + + return self.battle_default() + + def battle_4(self): + return self.clear_boss() diff --git a/campaign/war_archives_20220818_cn/sp2.py b/campaign/war_archives_20220818_cn/sp2.py new file mode 100644 index 000000000..d6883a2d7 --- /dev/null +++ b/campaign/war_archives_20220818_cn/sp2.py @@ -0,0 +1,76 @@ +from .campaign_base import CampaignBase +from module.map.map_base import CampaignMap +from module.map.map_grids import SelectedGrids, RoadGrids +from module.logger import logger +from .sp1 import Config as ConfigBase + +MAP = CampaignMap('SP2') +MAP.shape = 'I8' +MAP.camera_data = ['D3', 'D6'] +MAP.camera_data_spawn_point = ['D3'] +MAP.map_data = """ + ++ -- -- ++ -- -- ++ ++ -- + -- SP -- Me -- -- ++ ++ -- + -- -- -- -- -- MS -- -- -- + -- SP -- Me -- -- Me -- -- + ++ ++ ++ -- ME __ -- ME -- + -- ME -- Me -- -- ME -- -- + MB -- -- -- -- Me ++ ++ -- + -- ME -- ME ++ -- -- -- -- +""" +MAP.weight_data = """ + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 +""" +MAP.spawn_data = [ + {'battle': 0, 'enemy': 3, 'siren': 1}, + {'battle': 1, 'enemy': 2}, + {'battle': 2, 'enemy': 1}, + {'battle': 3, 'enemy': 1}, + {'battle': 4, 'boss': 1}, +] +A1, B1, C1, D1, E1, F1, G1, H1, I1, \ +A2, B2, C2, D2, E2, F2, G2, H2, I2, \ +A3, B3, C3, D3, E3, F3, G3, H3, I3, \ +A4, B4, C4, D4, E4, F4, G4, H4, I4, \ +A5, B5, C5, D5, E5, F5, G5, H5, I5, \ +A6, B6, C6, D6, E6, F6, G6, H6, I6, \ +A7, B7, C7, D7, E7, F7, G7, H7, I7, \ +A8, B8, C8, D8, E8, F8, G8, H8, I8, \ + = MAP.flatten() + + +class Config(ConfigBase): + # ===== Start of generated config ===== + MAP_SIREN_TEMPLATE = ['Magdeburg', 'PrinzAdalbert', 'GrafZeppelin'] + MOVABLE_ENEMY_TURN = (2,) + MAP_HAS_SIREN = True + MAP_HAS_MOVABLE_ENEMY = True + MAP_HAS_MAP_STORY = True + MAP_HAS_FLEET_STEP = True + MAP_HAS_AMBUSH = True + MAP_HAS_MYSTERY = False + # ===== End of generated config ===== + + +class Campaign(CampaignBase): + MAP = MAP + ENEMY_FILTER = '1L > 1M > 1E > 1C > 2L > 2M > 2E > 2C > 3L > 3M > 3E > 3C' + MAP_AIR_RAID_OVERLAY_TRANSPARENCY_THRESHOLD = 0.25 + + def battle_0(self): + if self.clear_siren(): + return True + if self.clear_filter_enemy(self.ENEMY_FILTER, preserve=0): + return True + + return self.battle_default() + + def battle_4(self): + return self.clear_boss() diff --git a/campaign/war_archives_20220818_cn/sp3.py b/campaign/war_archives_20220818_cn/sp3.py new file mode 100644 index 000000000..4b7e509c4 --- /dev/null +++ b/campaign/war_archives_20220818_cn/sp3.py @@ -0,0 +1,81 @@ +from .campaign_base import CampaignBase +from module.map.map_base import CampaignMap +from module.map.map_grids import SelectedGrids, RoadGrids +from module.logger import logger +from .sp1 import Config as ConfigBase + +MAP = CampaignMap('SP3') +MAP.shape = 'H8' +MAP.camera_data = ['D5', 'E3', 'E5'] +MAP.camera_data_spawn_point = ['D5'] +MAP.map_data = """ + -- -- -- -- ++ ++ -- -- + ++ ++ Me -- Me ++ ME -- + -- -- -- -- -- ME -- -- + SP -- -- MS __ -- -- MB + SP -- -- MS -- ME -- -- + -- ++ Me -- Me -- -- ME + -- ME -- ++ ++ ME ME ++ + -- -- -- ++ ++ -- -- ++ +""" +MAP.weight_data = """ + 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 +""" +MAP.spawn_data = [ + {'battle': 0, 'enemy': 3, 'siren': 2}, + {'battle': 1, 'enemy': 2}, + {'battle': 2, 'enemy': 1}, + {'battle': 3, 'enemy': 1}, + {'battle': 4}, + {'battle': 5, 'boss': 1}, +] +A1, B1, C1, D1, E1, F1, G1, H1, \ +A2, B2, C2, D2, E2, F2, G2, H2, \ +A3, B3, C3, D3, E3, F3, G3, H3, \ +A4, B4, C4, D4, E4, F4, G4, H4, \ +A5, B5, C5, D5, E5, F5, G5, H5, \ +A6, B6, C6, D6, E6, F6, G6, H6, \ +A7, B7, C7, D7, E7, F7, G7, H7, \ +A8, B8, C8, D8, E8, F8, G8, H8, \ + = MAP.flatten() + + +class Config(ConfigBase): + # ===== Start of generated config ===== + MAP_SIREN_TEMPLATE = ['GrafZeppelin', 'Weser', 'PeterStrasser'] + MOVABLE_ENEMY_TURN = (2,) + MAP_HAS_SIREN = True + MAP_HAS_MOVABLE_ENEMY = True + MAP_HAS_MAP_STORY = True + MAP_HAS_FLEET_STEP = True + MAP_HAS_AMBUSH = True + MAP_HAS_MYSTERY = False + # ===== End of generated config ===== + + MAP_SWIPE_MULTIPLY = (1.091, 1.112) + MAP_SWIPE_MULTIPLY_MINITOUCH = (1.056, 1.075) + MAP_SWIPE_MULTIPLY_MAATOUCH = (1.025, 1.043) + + +class Campaign(CampaignBase): + MAP = MAP + ENEMY_FILTER = '1L > 1M > 1E > 1C > 2L > 2M > 2E > 2C > 3L > 3M > 3E > 3C' + MAP_AIR_RAID_OVERLAY_TRANSPARENCY_THRESHOLD = 0.25 + + def battle_0(self): + if self.clear_siren(): + return True + if self.clear_filter_enemy(self.ENEMY_FILTER, preserve=0): + return True + + return self.battle_default() + + def battle_5(self): + return self.fleet_boss.clear_boss() diff --git a/campaign/war_archives_20220818_cn/sp4.py b/campaign/war_archives_20220818_cn/sp4.py new file mode 100644 index 000000000..01be8b986 --- /dev/null +++ b/campaign/war_archives_20220818_cn/sp4.py @@ -0,0 +1,84 @@ +from .campaign_base import CampaignBase +from module.map.map_base import CampaignMap +from module.map.map_grids import SelectedGrids, RoadGrids +from module.logger import logger +from .sp1 import Config as ConfigBase + +MAP = CampaignMap('SP4') +MAP.shape = 'I9' +MAP.camera_data = ['D6', 'F6', 'E3'] +MAP.camera_data_spawn_point = ['E7'] +MAP.map_data = """ + -- -- -- ME -- ME -- -- -- + -- ++ ME -- MB -- ME ++ -- + -- -- -- -- Me -- -- -- -- + -- ++ ++ -- -- -- ++ ++ -- + -- ++ ++ Me MS Me ++ ++ -- + -- ME MS -- __ -- MS ME -- + ME -- -- ++ -- ++ -- -- ME + -- ME -- -- -- -- -- ME -- + ++ ++ ++ SP -- SP ++ ++ ++ +""" +MAP.weight_data = """ + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 +""" +MAP.spawn_data = [ + {'battle': 0, 'enemy': 3, 'siren': 2}, + {'battle': 1, 'enemy': 2, 'siren': 1}, + {'battle': 2, 'enemy': 1}, + {'battle': 3, 'enemy': 1}, + {'battle': 4}, + {'battle': 5, 'boss': 1}, +] +A1, B1, C1, D1, E1, F1, G1, H1, I1, \ +A2, B2, C2, D2, E2, F2, G2, H2, I2, \ +A3, B3, C3, D3, E3, F3, G3, H3, I3, \ +A4, B4, C4, D4, E4, F4, G4, H4, I4, \ +A5, B5, C5, D5, E5, F5, G5, H5, I5, \ +A6, B6, C6, D6, E6, F6, G6, H6, I6, \ +A7, B7, C7, D7, E7, F7, G7, H7, I7, \ +A8, B8, C8, D8, E8, F8, G8, H8, I8, \ +A9, B9, C9, D9, E9, F9, G9, H9, I9, \ + = MAP.flatten() + + +class Config(ConfigBase): + # ===== Start of generated config ===== + MAP_SIREN_TEMPLATE = ['UlrichVonHutten'] + MOVABLE_ENEMY_TURN = (2,) + MAP_HAS_SIREN = True + MAP_HAS_MOVABLE_ENEMY = True + MAP_HAS_MAP_STORY = False + MAP_HAS_FLEET_STEP = True + MAP_HAS_AMBUSH = True + MAP_HAS_MYSTERY = False + # ===== End of generated config ===== + + MAP_SWIPE_MULTIPLY = (0.995, 1.013) + MAP_SWIPE_MULTIPLY_MINITOUCH = (0.962, 0.980) + MAP_SWIPE_MULTIPLY_MAATOUCH = (0.934, 0.951) + + +class Campaign(CampaignBase): + MAP = MAP + ENEMY_FILTER = '1L > 1M > 1E > 1C > 2L > 2M > 2E > 2C > 3L > 3M > 3E > 3C' + MAP_AIR_RAID_OVERLAY_TRANSPARENCY_THRESHOLD = 0.25 + + def battle_0(self): + if self.clear_siren(): + return True + if self.clear_filter_enemy(self.ENEMY_FILTER, preserve=0): + return True + + return self.battle_default() + + def battle_5(self): + return self.fleet_boss.clear_boss() diff --git a/campaign/war_archives_20230803_cn/campaign_base.py b/campaign/war_archives_20230803_cn/campaign_base.py new file mode 100644 index 000000000..ab0720f46 --- /dev/null +++ b/campaign/war_archives_20230803_cn/campaign_base.py @@ -0,0 +1,7 @@ +from ..campaign_war_archives.campaign_base import CampaignBase as CampaignBase_ + + +class CampaignBase(CampaignBase_): + STAGE_INCREASE = [ + 'SP1 > SP2 > SP3', + ] diff --git a/campaign/war_archives_20230803_cn/sp1.py b/campaign/war_archives_20230803_cn/sp1.py new file mode 100644 index 000000000..2c92e5099 --- /dev/null +++ b/campaign/war_archives_20230803_cn/sp1.py @@ -0,0 +1,104 @@ +from .campaign_base import CampaignBase +from module.map.map_base import CampaignMap +from module.map.map_grids import SelectedGrids, RoadGrids +from module.logger import logger + +MAP = CampaignMap('SP1') +MAP.shape = 'I6' +MAP.camera_data = ['F2', 'F4'] +MAP.camera_data_spawn_point = ['D2', 'D4'] +MAP.map_data = """ + ++ ++ ++ -- -- ME -- -- -- + -- -- Me -- Me -- Me ++ ++ + SP -- -- -- -- ME -- MB ++ + -- -- -- MS -- -- __ -- ME + SP -- -- -- ++ ME -- ME -- + -- ++ ME -- Me -- ME ++ -- +""" +MAP.weight_data = """ + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 +""" +MAP.spawn_data = [ + {'battle': 0, 'enemy': 1, 'siren': 1}, + {'battle': 1, 'enemy': 1}, + {'battle': 2, 'enemy': 1}, + {'battle': 3, 'enemy': 1}, + {'battle': 4, 'boss': 1}, +] +A1, B1, C1, D1, E1, F1, G1, H1, I1, \ +A2, B2, C2, D2, E2, F2, G2, H2, I2, \ +A3, B3, C3, D3, E3, F3, G3, H3, I3, \ +A4, B4, C4, D4, E4, F4, G4, H4, I4, \ +A5, B5, C5, D5, E5, F5, G5, H5, I5, \ +A6, B6, C6, D6, E6, F6, G6, H6, I6, \ + = MAP.flatten() + + +class Config: + # ===== Start of generated config ===== + MAP_SIREN_TEMPLATE = ['DD'] + MOVABLE_ENEMY_TURN = (2,) + MAP_HAS_SIREN = True + MAP_HAS_MOVABLE_ENEMY = True + MAP_HAS_MAP_STORY = False + MAP_HAS_FLEET_STEP = True + MAP_HAS_AMBUSH = False + MAP_HAS_MYSTERY = False + # ===== End of generated config ===== + + MAP_HAS_WALK_SPEEDUP = True + MAP_HAS_MOVABLE_NORMAL_ENEMY = True + MOVABLE_NORMAL_ENEMY_TURN = (2,) + MAP_SIREN_MOVE_WAIT = 0.5 + + MAP_WALK_USE_CURRENT_FLEET = True + INTERNAL_LINES_FIND_PEAKS_PARAMETERS = { + 'height': (80, 255 - 24), + 'width': (0.9, 10), + 'prominence': 10, + 'distance': 35, + } + EDGE_LINES_FIND_PEAKS_PARAMETERS = { + 'height': (255 - 24, 255), + 'prominence': 10, + 'distance': 50, + 'wlen': 1000 + } + HOMO_EDGE_COLOR_RANGE = (0, 24) + MAP_ENSURE_EDGE_INSIGHT_CORNER = 'bottom' + MAP_ENEMY_GENRE_DETECTION_SCALING = { + 'DD': 1.111, + 'CL': 1.111, + 'CAred': 1.111, + 'BBred': 1.111, + 'CV': 1.111, + } + + MAP_SWIPE_MULTIPLY = (1.179, 1.201) + MAP_SWIPE_MULTIPLY_MINITOUCH = (1.140, 1.161) + MAP_SWIPE_MULTIPLY_MAATOUCH = (1.107, 1.127) + + +class Campaign(CampaignBase): + MAP = MAP + ENEMY_FILTER = '1L > 1M > 1E > 1C > 2L > 2M > 2E > 2C > 3L > 3M > 3E > 3C' + + def battle_0(self): + if self.map_is_clear_mode: + if self.clear_siren(): + return True + if self.clear_filter_enemy(self.ENEMY_FILTER, preserve=1): + return True + else: + if self.clear_any_enemy(sort=('cost_2',)): + return True + + return self.battle_default() + + def battle_4(self): + return self.clear_boss() diff --git a/campaign/war_archives_20230803_cn/sp2.py b/campaign/war_archives_20230803_cn/sp2.py new file mode 100644 index 000000000..93656d57c --- /dev/null +++ b/campaign/war_archives_20230803_cn/sp2.py @@ -0,0 +1,80 @@ +from .campaign_base import CampaignBase +from module.map.map_base import CampaignMap +from module.map.map_grids import SelectedGrids, RoadGrids +from module.logger import logger +from .sp1 import Config as ConfigBase + +MAP = CampaignMap('SP2') +MAP.shape = 'H7' +MAP.camera_data = ['D2', 'D5', 'E2', 'E5'] +MAP.camera_data_spawn_point = ['E5', 'D5'] +MAP.map_data = """ + ++ ME -- -- -- -- ME -- + ME -- -- Me Me -- ++ -- + ME -- Me ++ ++ ME ++ ME + -- __ -- ++ ++ -- Me -- + ME -- MS MB MB MS __ ME + ++ -- -- -- -- -- -- ME + ++ ME -- SP SP -- ME ++ +""" +MAP.weight_data = """ + 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 +""" +MAP.spawn_data = [ + {'battle': 0, 'enemy': 2, 'siren': 2}, + {'battle': 1, 'enemy': 2}, + {'battle': 2, 'enemy': 1}, + {'battle': 3, 'enemy': 1}, + {'battle': 4, 'boss': 1}, +] +A1, B1, C1, D1, E1, F1, G1, H1, \ +A2, B2, C2, D2, E2, F2, G2, H2, \ +A3, B3, C3, D3, E3, F3, G3, H3, \ +A4, B4, C4, D4, E4, F4, G4, H4, \ +A5, B5, C5, D5, E5, F5, G5, H5, \ +A6, B6, C6, D6, E6, F6, G6, H6, \ +A7, B7, C7, D7, E7, F7, G7, H7, \ + = MAP.flatten() + + +class Config(ConfigBase): + # ===== Start of generated config ===== + MAP_SIREN_TEMPLATE = ['CL', 'CAred'] + MOVABLE_ENEMY_TURN = (2,) + MAP_HAS_SIREN = True + MAP_HAS_MOVABLE_ENEMY = True + MAP_HAS_MAP_STORY = True + MAP_HAS_FLEET_STEP = True + MAP_HAS_AMBUSH = False + MAP_HAS_MYSTERY = False + # ===== End of generated config ===== + + MAP_SWIPE_MULTIPLY = (1.133, 1.155) + MAP_SWIPE_MULTIPLY_MINITOUCH = (1.096, 1.116) + MAP_SWIPE_MULTIPLY_MAATOUCH = (1.064, 1.083) + + +class Campaign(CampaignBase): + MAP = MAP + ENEMY_FILTER = '1L > 1M > 1E > 1C > 2L > 2M > 2E > 2C > 3L > 3M > 3E > 3C' + + def battle_0(self): + if self.map_is_clear_mode: + if self.clear_siren(): + return True + if self.clear_filter_enemy(self.ENEMY_FILTER, preserve=1): + return True + else: + if self.clear_any_enemy(sort=('cost_2',)): + return True + + return self.battle_default() + + def battle_4(self): + return self.clear_boss() diff --git a/campaign/war_archives_20230803_cn/sp3.py b/campaign/war_archives_20230803_cn/sp3.py new file mode 100644 index 000000000..477c67f57 --- /dev/null +++ b/campaign/war_archives_20230803_cn/sp3.py @@ -0,0 +1,86 @@ +from .campaign_base import CampaignBase +from module.map.map_base import CampaignMap +from module.map.map_grids import SelectedGrids, RoadGrids +from module.logger import logger +from .sp1 import Config as ConfigBase + +MAP = CampaignMap('SP3') +MAP.shape = 'I8' +MAP.camera_data = ['D2', 'D4', 'D6', 'F2', 'F4', 'F6'] +MAP.camera_data_spawn_point = ['F2', 'D2'] +MAP.map_data = """ + -- -- ME ++ ++ ++ ME -- -- + ++ Me -- -- MB -- -- Me ++ + ME -- -- SP -- SP -- -- ME + -- MS -- -- __ -- -- MS -- + ME -- ++ -- ++ -- ++ -- ME + -- Me ++ MS -- MS ++ Me -- + ME -- Me -- -- -- Me -- ME + ++ ME -- ++ ++ ++ -- ME ++ +""" +MAP.weight_data = """ + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 + 50 50 50 50 50 50 50 50 50 +""" +MAP.spawn_data = [ + {'battle': 0, 'enemy': 2, 'siren': 2}, + {'battle': 1, 'enemy': 2, 'siren': 1}, + {'battle': 2, 'enemy': 2}, + {'battle': 3, 'enemy': 1}, + {'battle': 4, 'enemy': 1}, + {'battle': 5, 'boss': 1}, +] +A1, B1, C1, D1, E1, F1, G1, H1, I1, \ +A2, B2, C2, D2, E2, F2, G2, H2, I2, \ +A3, B3, C3, D3, E3, F3, G3, H3, I3, \ +A4, B4, C4, D4, E4, F4, G4, H4, I4, \ +A5, B5, C5, D5, E5, F5, G5, H5, I5, \ +A6, B6, C6, D6, E6, F6, G6, H6, I6, \ +A7, B7, C7, D7, E7, F7, G7, H7, I7, \ +A8, B8, C8, D8, E8, F8, G8, H8, I8, \ + = MAP.flatten() + + +class Config(ConfigBase): + # ===== Start of generated config ===== + MAP_SIREN_TEMPLATE = ['SirenBoss15'] + MOVABLE_ENEMY_TURN = (2,) + MAP_HAS_SIREN = True + MAP_HAS_MOVABLE_ENEMY = True + MAP_HAS_MAP_STORY = False + MAP_HAS_FLEET_STEP = True + MAP_HAS_AMBUSH = False + MAP_HAS_MYSTERY = False + # ===== End of generated config ===== + + HOMO_EDGE_HOUGHLINES_THRESHOLD = 210 + + MAP_SWIPE_MULTIPLY = (1.205, 1.227) + MAP_SWIPE_MULTIPLY_MINITOUCH = (1.165, 1.187) + MAP_SWIPE_MULTIPLY_MAATOUCH = (1.131, 1.151) + + +class Campaign(CampaignBase): + MAP = MAP + ENEMY_FILTER = '1L > 1M > 1E > 1C > 2L > 2M > 2E > 2C > 3L > 3M > 3E > 3C' + + def battle_0(self): + if self.map_is_clear_mode: + if self.clear_siren(): + return True + if self.clear_filter_enemy(self.ENEMY_FILTER, preserve=1): + return True + else: + if self.clear_any_enemy(sort=('cost_2',)): + return True + + return self.battle_default() + + def battle_5(self): + return self.fleet_boss.clear_boss() diff --git a/config/template.json b/config/template.json index 8fd8a1558..aef804051 100644 --- a/config/template.json +++ b/config/template.json @@ -669,7 +669,7 @@ }, "Campaign": { "Name": "D3", - "Event": "war_archives_20230223_cn", + "Event": "war_archives_20230803_cn", "Mode": "normal", "UseClearMode": true, "UseFleetLock": true, diff --git a/module/config/argument/args.json b/module/config/argument/args.json index 63ad123fa..ceaf1c111 100644 --- a/module/config/argument/args.json +++ b/module/config/argument/args.json @@ -3494,12 +3494,16 @@ "war_archives_20220428_cn", "war_archives_20220526_cn", "war_archives_20220728_cn", + "war_archives_20220818_cn", "war_archives_20220915_cn", "war_archives_20221222_cn", "war_archives_20230223_cn", + "war_archives_20230803_cn", "war_archives_20231026_cn" ], "option_cn": [ + "war_archives_20230803_cn", + "war_archives_20220818_cn", "war_archives_20230223_cn", "war_archives_20221222_cn", "war_archives_20220915_cn", @@ -3546,6 +3550,8 @@ "war_archives_20181020_en" ], "option_en": [ + "war_archives_20230803_cn", + "war_archives_20220818_cn", "war_archives_20230223_cn", "war_archives_20221222_cn", "war_archives_20220915_cn", @@ -3592,6 +3598,8 @@ "war_archives_20181020_en" ], "option_jp": [ + "war_archives_20230803_cn", + "war_archives_20220818_cn", "war_archives_20230223_cn", "war_archives_20221222_cn", "war_archives_20220915_cn", @@ -3638,6 +3646,8 @@ "war_archives_20181020_en" ], "option_tw": [ + "war_archives_20230803_cn", + "war_archives_20220818_cn", "war_archives_20230223_cn", "war_archives_20221222_cn", "war_archives_20220915_cn", diff --git a/module/config/i18n/en-US.json b/module/config/i18n/en-US.json index af6eb61c3..690eb97f5 100644 --- a/module/config/i18n/en-US.json +++ b/module/config/i18n/en-US.json @@ -821,9 +821,11 @@ "war_archives_20220428_cn": "archives Rondo at Rainbows End", "war_archives_20220526_cn": "archives Pledge of the Radiant Court", "war_archives_20220728_cn": "archives Aquilifers Ballade", + "war_archives_20220818_cn": "archives Operation Convergence", "war_archives_20220915_cn": "archives Violet Tempest Blooming Lycoris", "war_archives_20221222_cn": "archives Parallel Superimposition", "war_archives_20230223_cn": "archives Revelations of Dust", + "war_archives_20230803_cn": "archives Anthem of Remembrance", "war_archives_20231026_cn": "archives Tempesta and the Fountain of Youth" }, "Mode": { diff --git a/module/config/i18n/ja-JP.json b/module/config/i18n/ja-JP.json index c7b68226d..b98863229 100644 --- a/module/config/i18n/ja-JP.json +++ b/module/config/i18n/ja-JP.json @@ -821,9 +821,11 @@ "war_archives_20220428_cn": "檔案 吟ずる瑠璃の楽章", "war_archives_20220526_cn": "檔案 诚閃の剣 搖光の城", "war_archives_20220728_cn": "檔案 鋼鷲の冒険譚", + "war_archives_20220818_cn": "檔案 結像点作戦", "war_archives_20220915_cn": "檔案 赫の涙月 菫の暁風", "war_archives_20221222_cn": "檔案 積重なる事象の幻界", "war_archives_20230223_cn": "檔案 黙示の遺構", + "war_archives_20230803_cn": "檔案 燃ゆる聖都の回想曲", "war_archives_20231026_cn": "檔案 テンペスタと若返りの泉" }, "Mode": { diff --git a/module/config/i18n/zh-CN.json b/module/config/i18n/zh-CN.json index c48b283dd..c2292a364 100644 --- a/module/config/i18n/zh-CN.json +++ b/module/config/i18n/zh-CN.json @@ -551,6 +551,12 @@ "default": "默认 (Cloudflare)", "cn_gz_reverse_proxy": "国内反向代理 (广州)" }, + "DailyRecord": { + "name": "每日挑战截图", + "help": "", + "do_not": "无操作", + "save": "保存" + }, "ResearchRecord": { "name": "科研截图", "help": "", @@ -821,9 +827,11 @@ "war_archives_20220428_cn": "档案 虹彩的终幕曲", "war_archives_20220526_cn": "档案 泠誓光庭", "war_archives_20220728_cn": "档案 雄鹰的叙事歌", + "war_archives_20220818_cn": "档案 远汇点作战", "war_archives_20220915_cn": "档案 紫绛槿岚", "war_archives_20221222_cn": "档案 定向折叠", "war_archives_20230223_cn": "档案 湮烬尘墟", + "war_archives_20230803_cn": "档案 奏响鸢尾之歌", "war_archives_20231026_cn": "档案 飓风与青春之泉" }, "Mode": { diff --git a/module/config/i18n/zh-TW.json b/module/config/i18n/zh-TW.json index 761ad94ee..7460cd98a 100644 --- a/module/config/i18n/zh-TW.json +++ b/module/config/i18n/zh-TW.json @@ -821,9 +821,11 @@ "war_archives_20220428_cn": "檔案 虹彩的終幕曲", "war_archives_20220526_cn": "檔案 泠誓光庭", "war_archives_20220728_cn": "檔案 雄鷹的敘事歌", + "war_archives_20220818_cn": "檔案 遠匯點作戰", "war_archives_20220915_cn": "檔案 紫絳槿嵐", "war_archives_20221222_cn": "檔案 定向折疊", "war_archives_20230223_cn": "檔案 湮燼塵墟", + "war_archives_20230803_cn": "檔案 奏響鳶尾之歌", "war_archives_20231026_cn": "檔案 飓風與青春之泉" }, "Mode": { diff --git a/module/war_archives/assets.py b/module/war_archives/assets.py index b95de8d8c..b1c41af68 100644 --- a/module/war_archives/assets.py +++ b/module/war_archives/assets.py @@ -6,6 +6,7 @@ from module.base.template import Template OCR_DATA_KEY_CAMPAIGN = Button(area={'cn': (1188, 107, 1272, 131), 'en': (1188, 107, 1272, 131), 'jp': (1188, 107, 1272, 131), 'tw': (1188, 107, 1272, 131)}, color={'cn': (104, 101, 107), 'en': (104, 101, 107), 'jp': (104, 101, 107), 'tw': (104, 101, 107)}, button={'cn': (1188, 107, 1272, 131), 'en': (1188, 107, 1272, 131), 'jp': (1188, 107, 1272, 131), 'tw': (1188, 107, 1272, 131)}, file={'cn': './assets/cn/war_archives/OCR_DATA_KEY_CAMPAIGN.png', 'en': './assets/en/war_archives/OCR_DATA_KEY_CAMPAIGN.png', 'jp': './assets/jp/war_archives/OCR_DATA_KEY_CAMPAIGN.png', 'tw': './assets/tw/war_archives/OCR_DATA_KEY_CAMPAIGN.png'}) TEMPLATE_ABYSSAL_REFRAIN = Template(file={'cn': './assets/cn/war_archives/TEMPLATE_ABYSSAL_REFRAIN.png', 'en': './assets/cn/war_archives/TEMPLATE_ABYSSAL_REFRAIN.png', 'jp': './assets/cn/war_archives/TEMPLATE_ABYSSAL_REFRAIN.png', 'tw': './assets/cn/war_archives/TEMPLATE_ABYSSAL_REFRAIN.png'}) +TEMPLATE_ANTHEM_OF_REMEMBRANCE = Template(file={'cn': './assets/cn/war_archives/TEMPLATE_ANTHEM_OF_REMEMBRANCE.png', 'en': './assets/cn/war_archives/TEMPLATE_ANTHEM_OF_REMEMBRANCE.png', 'jp': './assets/cn/war_archives/TEMPLATE_ANTHEM_OF_REMEMBRANCE.png', 'tw': './assets/cn/war_archives/TEMPLATE_ANTHEM_OF_REMEMBRANCE.png'}) TEMPLATE_AQUILIFERS_BALLADE = Template(file={'cn': './assets/cn/war_archives/TEMPLATE_AQUILIFERS_BALLADE.png', 'en': './assets/cn/war_archives/TEMPLATE_AQUILIFERS_BALLADE.png', 'jp': './assets/cn/war_archives/TEMPLATE_AQUILIFERS_BALLADE.png', 'tw': './assets/cn/war_archives/TEMPLATE_AQUILIFERS_BALLADE.png'}) TEMPLATE_ASHEN_SIMULACRUM = Template(file={'cn': './assets/cn/war_archives/TEMPLATE_ASHEN_SIMULACRUM.png', 'en': './assets/en/war_archives/TEMPLATE_ASHEN_SIMULACRUM.png', 'jp': './assets/cn/war_archives/TEMPLATE_ASHEN_SIMULACRUM.png', 'tw': './assets/cn/war_archives/TEMPLATE_ASHEN_SIMULACRUM.png'}) TEMPLATE_AURORA_NOCTIS = Template(file={'cn': './assets/cn/war_archives/TEMPLATE_AURORA_NOCTIS.png', 'en': './assets/en/war_archives/TEMPLATE_AURORA_NOCTIS.png', 'jp': './assets/cn/war_archives/TEMPLATE_AURORA_NOCTIS.png', 'tw': './assets/cn/war_archives/TEMPLATE_AURORA_NOCTIS.png'}) @@ -27,6 +28,7 @@ TEMPLATE_MICROLAYER_MEDLEY = Template(file={'cn': './assets/cn/war_archives/TEMP TEMPLATE_MIRROR_INVOLUTION = Template(file={'cn': './assets/cn/war_archives/TEMPLATE_MIRROR_INVOLUTION.png', 'en': './assets/cn/war_archives/TEMPLATE_MIRROR_INVOLUTION.png', 'jp': './assets/cn/war_archives/TEMPLATE_MIRROR_INVOLUTION.png', 'tw': './assets/cn/war_archives/TEMPLATE_MIRROR_INVOLUTION.png'}) TEMPLATE_MOONLIT_OVERTURE = Template(file={'cn': './assets/cn/war_archives/TEMPLATE_MOONLIT_OVERTURE.png', 'en': './assets/cn/war_archives/TEMPLATE_MOONLIT_OVERTURE.png', 'jp': './assets/cn/war_archives/TEMPLATE_MOONLIT_OVERTURE.png', 'tw': './assets/cn/war_archives/TEMPLATE_MOONLIT_OVERTURE.png'}) TEMPLATE_NORTHERN_OVERTURE = Template(file={'cn': './assets/cn/war_archives/TEMPLATE_NORTHERN_OVERTURE.png', 'en': './assets/en/war_archives/TEMPLATE_NORTHERN_OVERTURE.png', 'jp': './assets/cn/war_archives/TEMPLATE_NORTHERN_OVERTURE.png', 'tw': './assets/cn/war_archives/TEMPLATE_NORTHERN_OVERTURE.png'}) +TEMPLATE_OPERATION_CONVERGENCE = Template(file={'cn': './assets/cn/war_archives/TEMPLATE_OPERATION_CONVERGENCE.png', 'en': './assets/cn/war_archives/TEMPLATE_OPERATION_CONVERGENCE.png', 'jp': './assets/cn/war_archives/TEMPLATE_OPERATION_CONVERGENCE.png', 'tw': './assets/cn/war_archives/TEMPLATE_OPERATION_CONVERGENCE.png'}) TEMPLATE_PARALLEL_SUPERIMPOSITION = Template(file={'cn': './assets/cn/war_archives/TEMPLATE_PARALLEL_SUPERIMPOSITION.png', 'en': './assets/cn/war_archives/TEMPLATE_PARALLEL_SUPERIMPOSITION.png', 'jp': './assets/cn/war_archives/TEMPLATE_PARALLEL_SUPERIMPOSITION.png', 'tw': './assets/cn/war_archives/TEMPLATE_PARALLEL_SUPERIMPOSITION.png'}) TEMPLATE_PLEDGE_OF_THE_RADIANT_COURT = Template(file={'cn': './assets/cn/war_archives/TEMPLATE_PLEDGE_OF_THE_RADIANT_COURT.png', 'en': './assets/cn/war_archives/TEMPLATE_PLEDGE_OF_THE_RADIANT_COURT.png', 'jp': './assets/cn/war_archives/TEMPLATE_PLEDGE_OF_THE_RADIANT_COURT.png', 'tw': './assets/cn/war_archives/TEMPLATE_PLEDGE_OF_THE_RADIANT_COURT.png'}) TEMPLATE_PRELUDE_UNDER_THE_MOON = Template(file={'cn': './assets/cn/war_archives/TEMPLATE_PRELUDE_UNDER_THE_MOON.png', 'en': './assets/cn/war_archives/TEMPLATE_PRELUDE_UNDER_THE_MOON.png', 'jp': './assets/cn/war_archives/TEMPLATE_PRELUDE_UNDER_THE_MOON.png', 'tw': './assets/cn/war_archives/TEMPLATE_PRELUDE_UNDER_THE_MOON.png'}) diff --git a/module/war_archives/dictionary.py b/module/war_archives/dictionary.py index d7cce3888..6c965187e 100644 --- a/module/war_archives/dictionary.py +++ b/module/war_archives/dictionary.py @@ -45,4 +45,6 @@ dic_archives_template = { 'war_archives_20220915_cn': TEMPLATE_VIOLET_TEMPEST_BLOOMING_LYCORIS, 'war_archives_20221222_cn': TEMPLATE_PARALLEL_SUPERIMPOSITION, 'war_archives_20230223_cn': TEMPLATE_REVELATIONS_OF_DUST, + 'war_archives_20220818_cn': TEMPLATE_OPERATION_CONVERGENCE, + 'war_archives_20230803_cn': TEMPLATE_ANTHEM_OF_REMEMBRANCE, }