diff options
Diffstat (limited to 'engines/kyra/staticres.cpp')
-rw-r--r-- | engines/kyra/staticres.cpp | 44 |
1 files changed, 30 insertions, 14 deletions
diff --git a/engines/kyra/staticres.cpp b/engines/kyra/staticres.cpp index 38d8d4d284..f9238ff044 100644 --- a/engines/kyra/staticres.cpp +++ b/engines/kyra/staticres.cpp @@ -43,7 +43,7 @@ namespace Kyra { -#define RESFILE_VERSION 28 +#define RESFILE_VERSION 29 bool StaticResource::checkKyraDat() { Common::File kyraDat; @@ -279,6 +279,16 @@ bool StaticResource::init() { { 0, 0, 0 } }; + static const FilenameTable lolStaticRes[] = { + // Demo Sequence Player + { k2SeqplayPakFiles, kStringList, "S_PAKFILES.TXT" }, + { k2SeqplayStrings, kLanguageList, "S_STRINGS." }, + { k2SeqplaySfxFiles, kStringList, "S_SFXFILES.TXT" }, + { k2SeqplaySeqData, k2SeqData, "S_DATA.SEQ" }, + { k2SeqplayIntroTracks, kStringList, "S_INTRO.TRA" }, + { 0, 0, 0 } + }; + if (_vm->game() == GI_KYRA1) { _builtIn = 0; _filenameTable = kyra1StaticRes; @@ -289,7 +299,10 @@ bool StaticResource::init() { _builtIn = 0; _filenameTable = kyra3StaticRes; } else if (_vm->game() == GI_LOL) { - return true; + if (!_vm->gameFlags().isDemo) + return true; + _builtIn = 0; + _filenameTable = lolStaticRes; } else { error("StaticResource: Unknown game ID"); } @@ -920,6 +933,8 @@ const char *StaticResource::getFilename(const char *name) { filename += ".K2"; else if (_vm->gameFlags().gameID == GI_KYRA3) filename += ".K3"; + else if (_vm->gameFlags().gameID == GI_LOL) + filename += ".LOL"; if (_vm->gameFlags().isTalkie && _vm->gameFlags().gameID != GI_KYRA3) filename += ".CD"; @@ -1037,10 +1052,8 @@ void KyraEngine_LoK::initStaticResource() { } // audio data tables -#if 0 static const char *tIntro98[] = { "intro%d.dat" }; static const char *tIngame98[] = { "kyram%d.dat" }; -#endif static const AudioDataStruct soundData_PC[] = { { _soundFilesIntro, _soundFilesIntroSize, 0, 0 }, @@ -1054,20 +1067,18 @@ void KyraEngine_LoK::initStaticResource() { { 0, 0, 0, 0} }; -#if 0 static const AudioDataStruct soundData_PC98[] = { { tIntro98, 1, 0, 0 }, { tIngame98, 1, 0, 0 }, { 0, 0, 0, 0} }; -#endif if (_flags.platform == Common::kPlatformPC) _soundData = soundData_PC; else if (_flags.platform == Common::kPlatformFMTowns) _soundData = soundData_TOWNS; else if (_flags.platform == Common::kPlatformPC98) - _soundData = soundData_TOWNS/*soundData_PC98*/; + _soundData = soundData_PC98; else _soundData = 0; } @@ -1267,11 +1278,9 @@ void KyraEngine_HoF::initStaticResource() { static const char *fmtMusicFileListFinale[] = { "finale%d.twn" }; static const char *fmtMusicFileListIngame[] = { "km%02d.twn" }; -#if 0 static const char *pc98MusicFileListIntro[] = { "intro%d.86" }; static const char *pc98MusicFileListFinale[] = { "finale%d.86" }; static const char *pc98MusicFileListIngame[] = { "km%02d.86" }; -#endif static const AudioDataStruct soundData_PC[] = { { _musicFileListIntro, _musicFileListIntroSize, 0, 0 }, @@ -1285,20 +1294,18 @@ void KyraEngine_HoF::initStaticResource() { { fmtMusicFileListFinale, 1, _cdaTrackTableFinale, _cdaTrackTableFinaleSize >> 1 } }; -#if 0 static const AudioDataStruct soundData_PC98[] = { { pc98MusicFileListIntro, 1, 0, 0 }, { pc98MusicFileListIngame, 1, 0, 0 }, { pc98MusicFileListFinale, 1, 0, 0 } }; -#endif if (_flags.platform == Common::kPlatformPC) _soundData = soundData_PC; else if (_flags.platform == Common::kPlatformFMTowns) _soundData = soundData_TOWNS; else if (_flags.platform == Common::kPlatformPC98) - _soundData = soundData_TOWNS/*soundData_PC98*/; + _soundData = soundData_PC98; // setup sequence data _sequences = _staticres->loadHofSequenceData(k2SeqplaySeqData, tmpSize); @@ -1337,8 +1344,17 @@ void KyraEngine_HoF::initStaticResource() { &KyraEngine_HoF::seq_demoDig, 0 }; - _callbackS = (_flags.isDemo && !_flags.isTalkie) ? hofDemoSequenceCallbacks : hofSequenceCallbacks; - _callbackN = (_flags.isDemo && !_flags.isTalkie) ? hofDemoNestedSequenceCallbacks : hofNestedSequenceCallbacks; + static const SeqProc lolDemoSequenceCallbacks[] = { + &KyraEngine_HoF::seq_lolDemoScene1, 0, &KyraEngine_HoF::seq_lolDemoScene2, 0, + &KyraEngine_HoF::seq_lolDemoScene3, 0, &KyraEngine_HoF::seq_lolDemoScene4, 0, + &KyraEngine_HoF::seq_lolDemoScene5, &KyraEngine_HoF::seq_lolDemoText5, + &KyraEngine_HoF::seq_lolDemoScene6, 0 + }; + + static const SeqProc lolDemoNestedSequenceCallbacks[] = { 0 }; + + _callbackS = _flags.gameID == GI_LOL ? lolDemoSequenceCallbacks : ((_flags.isDemo && !_flags.isTalkie) ? hofDemoSequenceCallbacks : hofSequenceCallbacks); + _callbackN = _flags.gameID == GI_LOL ? lolDemoNestedSequenceCallbacks : ((_flags.isDemo && !_flags.isTalkie) ? hofDemoNestedSequenceCallbacks : hofNestedSequenceCallbacks); } void KyraEngine_MR::initStaticResource() { |