diff options
Diffstat (limited to '')
-rw-r--r-- | tools/MovieSettings.py | 26 |
1 files changed, 22 insertions, 4 deletions
diff --git a/tools/MovieSettings.py b/tools/MovieSettings.py index 1a6bbaf..1269e5c 100644 --- a/tools/MovieSettings.py +++ b/tools/MovieSettings.py @@ -9,8 +9,9 @@ class Settings(object): def add_sound(self, delay, sound_id): self.sounds.append((delay, sound_id)) - def __init__(self): + def __init__(self, widescreen): self.banners = [] + self.widescreen = widescreen def add_banner(self, name): b = self.Banner(name) @@ -28,10 +29,10 @@ class Settings(object): banner_offsets.append(offset) b_header1 = 'xxxx' # will be replaced later - b_header2 = struct.pack('>I', len(b.sounds)) + b_header2 = struct.pack('>bxxxI', 1 if self.widescreen else 0, len(b.sounds)) b_sounds = map(lambda x: struct.pack('>II', *x), b.sounds) - offset += 8 + (len(b_sounds) * 8) + offset += 12 + (len(b_sounds) * 8) b_data = [b_header1, b_header2] b_data.extend(b_sounds) @@ -64,7 +65,7 @@ class Settings(object): -s = Settings() +s = Settings(widescreen=False) b = s.add_banner('/CS/Opening1.arc') b = s.add_banner('/CS/Opening3.arc') @@ -81,4 +82,21 @@ b = s.add_banner('/CS/Opening11.arc') data = s.export() open('Opening.cs', 'wb').write(data) +s = Settings(widescreen=True) + +b = s.add_banner('/CS/Kamek1_2.arc') +b = s.add_banner('/CS/Kamek3_4.arc') +b = s.add_banner('/CS/Kamek5_6.arc') +b = s.add_banner('/CS/Kamek7_8.arc') +b = s.add_banner('/CS/Kamek9_10.arc') +b = s.add_banner('/CS/Kamek11.arc') +b = s.add_banner('/CS/Kamek12.arc') +b = s.add_banner('/CS/Kamek13_14.arc') +b = s.add_banner('/CS/Kamek15_16.arc') +b = s.add_banner('/CS/Kamek17.arc') + + +data = s.export() +open('Kamek.cs', 'wb').write(data) + |