diff --git a/unpack/downloader b/unpack/downloader index 71a730d..40970c5 160000 --- a/unpack/downloader +++ b/unpack/downloader @@ -1 +1 @@ -Subproject commit 71a730dbd88fac330da9ef73e2dd6a8b357d0d7f +Subproject commit 40970c55d30ed1748e0798d7efa272caf6097178 diff --git a/unpack/downloader.patch b/unpack/downloader.patch index 41b1a54..8d45df3 100644 --- a/unpack/downloader.patch +++ b/unpack/downloader.patch @@ -1,8 +1,8 @@ diff --git a/downloader.py b/downloader.py -index f81ca28..e5b6536 100644 +index 663194b..7879b7d 100644 --- a/downloader.py +++ b/downloader.py -@@ -139,6 +139,20 @@ if __name__ == "__main__": +@@ -140,6 +140,20 @@ if __name__ == "__main__": res_path = os.path.join( out_dir, abname if config["use_abname"] else resname ) @@ -23,7 +23,7 @@ index f81ca28..e5b6536 100644 if os.path.exists(res_path): if os.path.getsize(res_path) == size: logger.info(f"File {resname} already exists, thus will be skipped") -@@ -155,6 +169,8 @@ if __name__ == "__main__": +@@ -156,6 +170,8 @@ if __name__ == "__main__": res_path = os.path.join( out_dir, abname if config["use_abname"] else resname ) diff --git a/unpack/src/gfunpack/manual_chapters.py b/unpack/src/gfunpack/manual_chapters.py index dc8d07c..d27c5fa 100644 --- a/unpack/src/gfunpack/manual_chapters.py +++ b/unpack/src/gfunpack/manual_chapters.py @@ -166,6 +166,25 @@ def _extra_stories_sac2045(): ] +def _extra_stories_gunslinger(): + return [ + ('第九号', '', ['-38-0-1.txt']), + ('万花筒', '1', ['-38-1-1.txt']), + ('新叉子', '2/2战斗', ['-38-2-1.txt', '-38-2-2first.txt', '-38-2-2round.txt', '-38-2-2end.txt']), + ('薄暮的星星', '2幕间', ['-38-2-3.txt']), + ('多幕剧Ⅰ', '3', ['-38-3-1.txt']), + ('多幕剧Ⅱ', '3/3战斗', ['-38-3-1first.txt', '-38-3-2round.txt', '-38-3-2end.txt']), + ('幸福的魔法', '3幕间', ['-38-3-3.txt']), + ('公社射击训练场', '', ['battleavg/-38-specialbattletips.txt']), + ('不会说谎的匹诺曹Ⅰ', '4/4战斗', ['-38-4-1first.txt', '-38-4-1round.txt']), + ('不会说谎的匹诺曹Ⅱ', '4结算剧情', ['-38-4-1end.txt']), + ('曾经的庭院Ⅰ', '5/5战斗', ['-38-5-1first.txt', '-38-5-1round.txt']), + ('曾经的庭院Ⅱ', '5结算剧情', ['-38-5-1end.txt']), + ('Hai capito', '6战斗', ['-38-6-1first.txt', '-38-6-1round.txt', '-38-6-1end.txt']), + ('完美和声', '7结局', ['-38-7-1.txt']), + ] + + _extra_chapters: list[tuple[str, str, str, list]] = [ ('-42', 'C.E. 2020 茧中蝶影', '2020', _extra_stories_cocoon()), ('-50', 'C.E. 2022 焙炒爱意', '2022', []), @@ -178,7 +197,7 @@ def _extra_stories_sac2045(): ('-14,-15', '独法师', '《崩坏学园2》联动内容', []), ('-19,-20,-22', '荣耀日', '《DJMAX RESPECT》联动内容', []), ('-32', '瓦尔哈拉', '《VA-11 HALL-A》联动内容', _extra_stories_va11()), - ('-38', '梦间剧', '《神枪少女》联动内容', []), + ('-38', '梦间剧', '《神枪少女》联动内容', _extra_stories_gunslinger()), ('-43', '暗金潮', '《全境封锁》联动内容', []), ('-46', '小邪神前线', '《邪神与厨二病少女》联动内容', []), ('-57', '雪浪映花颜', '《佐贺偶像是传奇 卷土重来》联动内容', []), @@ -309,14 +328,14 @@ def get_recorded_chapters(): _attached_events: list[tuple[str, Story]] = [ # 裂变链接:吞噬一切的花海-战斗 ('-33-42-1first.txt', Story( - name="吞噬一切的花海-战斗", - description="小游戏说明", + name='吞噬一切的花海-战斗', + description='小游戏说明', files=['battleavg/-33-44-1first.txt'], )), # 愚人节 ('1-1-1.txt', Story( - name="演习训练-愚人节版", - description="欢迎回来,父亲大人。", + name='演习训练-愚人节版', + description='欢迎回来,父亲大人。', files=['always-404-1-1-1.txt', 'battleavg/always-404-1-1-2.txt', 'always-404-1-1-3.txt'], )), # 里坎禁猎区 @@ -615,10 +634,10 @@ def get_block_list(): '-65-tips2.txt', '-404-ext-1-1.txt', # 飓风营救复刻 (-45 -> -24) - "-45-ext-04.txt", - "-45-ext-01.txt", - "-45-ext-02.txt", - "-45-ext-03.txt", + '-45-ext-04.txt', + '-45-ext-01.txt', + '-45-ext-02.txt', + '-45-ext-03.txt', # 盲拆法则:这些是英文版 '-7-1-4-point3498.txt', @@ -626,8 +645,12 @@ def get_block_list(): '-7-3-4-point3533.txt', '-7-4-4-point3612.txt', - # 神枪少女联动,和 -38-ex-point91829.txt 内容一样 + # 神枪少女联动,玩法说明而已 '-38-ex-point91820.txt', + '-38-ex-point91829.txt', + '-38-ex1-5-point91849.txt', + '-38-ex1-2-point91865.txt', + '-38-2-4first.txt', # 和 '-38-2-1.txt', '-38-2-2first.txt' 重复,用了修了错别字的版本 # 一币之遥,游戏提示 '-49-3-1-point94780.txt', diff --git a/unpack/src/gfunpack/stories.py b/unpack/src/gfunpack/stories.py index df06a6f..1629144 100644 --- a/unpack/src/gfunpack/stories.py +++ b/unpack/src/gfunpack/stories.py @@ -240,6 +240,7 @@ def _generate_bg_line(self, bg: str, effects: dict[str, str]): if bg_path is None or bg_path == '': _warning('background not found for `%s` in %s', bg, self.filename) bg_path = f'background/{bg}.png' + self._update_class('night', 'night' in effects) night = 'night' if 'night' in effects else '!night' self._resources.add(f'/images/{bg_path}') return f':background[] :classes[{night}] /images/{bg_path}' @@ -290,10 +291,19 @@ def _process_effects(self, effect_string: str): continue self._markdown.append(self._generate_bg_line(cg.strip(), effects)) self._markdown.append('……' * i) + + # 一众的蒙版效果 + if '回忆' in effects: + self._update_class('memories', True) + # 关闭所有蒙版效果 + if '关闭蒙版' in effects: + self._update_class('memories', False) + self._update_class('night', False) + # 没猜错的和,这两个都是永久性黑屏,直至新的背景出现 if '黑屏1' in effects or '黑点1' in effects: self._update_class('blank', True) - # 没猜错的和,这两个都是暂时性黑屏,一定时间后消失 + # 没猜错的话,这两个都是暂时性黑屏,一定时间后消失 # 但的确不知道黑屏会不会挡住角色 if '黑屏2' in effects or '黑点2' in effects: self._update_class('blank', False)