diff options
author | Johannes Schickel | 2009-10-14 14:17:15 +0000 |
---|---|---|
committer | Johannes Schickel | 2009-10-14 14:17:15 +0000 |
commit | 51975b50cb8f95d15b3d9e63b8de4b590eb90016 (patch) | |
tree | ba3c92f2789cecd54a690d693032d007ea8755c9 | |
parent | c93c9cb68dded6d4a47de73c2de74d433b027439 (diff) | |
download | scummvm-rg350-51975b50cb8f95d15b3d9e63b8de4b590eb90016.tar.gz scummvm-rg350-51975b50cb8f95d15b3d9e63b8de4b590eb90016.tar.bz2 scummvm-rg350-51975b50cb8f95d15b3d9e63b8de4b590eb90016.zip |
Add LoL PC98 credits entries to kyra.dat.
svn-id: r45082
-rw-r--r-- | dists/engine-data/kyra.dat | bin | 298109 -> 299643 bytes | |||
-rw-r--r-- | engines/kyra/resource.h | 2 | ||||
-rw-r--r-- | engines/kyra/sequences_lol.cpp | 17 | ||||
-rw-r--r-- | engines/kyra/staticres.cpp | 8 | ||||
-rw-r--r-- | tools/create_kyradat/create_kyradat.cpp | 6 | ||||
-rw-r--r-- | tools/create_kyradat/create_kyradat.h | 2 | ||||
-rw-r--r-- | tools/create_kyradat/games.cpp | 14 | ||||
-rw-r--r-- | tools/create_kyradat/tables.cpp | 7 |
8 files changed, 48 insertions, 8 deletions
diff --git a/dists/engine-data/kyra.dat b/dists/engine-data/kyra.dat Binary files differindex 860538e052..9e0912feec 100644 --- a/dists/engine-data/kyra.dat +++ b/dists/engine-data/kyra.dat diff --git a/engines/kyra/resource.h b/engines/kyra/resource.h index 529d9f4c5a..d164a28972 100644 --- a/engines/kyra/resource.h +++ b/engines/kyra/resource.h @@ -298,6 +298,8 @@ enum KyraResources { kLolLightningDefs, kLolFireballCoords, + kLolCredits, + kLolHistory, #endif // ENABLE_LOL diff --git a/engines/kyra/sequences_lol.cpp b/engines/kyra/sequences_lol.cpp index 2a4b4910dd..da32c3a8e6 100644 --- a/engines/kyra/sequences_lol.cpp +++ b/engines/kyra/sequences_lol.cpp @@ -1182,7 +1182,22 @@ void LoLEngine::showCredits() { _screen->_charOffset = 0; - char *credits = (char *)_res->fileData("CREDITS.TXT", 0); + char *credits = 0; + + if (_flags.platform == Common::kPlatformPC98) { + int size = 0; + const uint8 *internCredits = _staticres->loadRawData(kLolCredits, size); + assert(size > 0); + + credits = new char[size]; + assert(credits); + + memcpy(credits, internCredits, size); + _staticres->unloadId(kLolCredits); + } else { + credits = (char *)_res->fileData("CREDITS.TXT", 0); + } + processCredits(credits, 21, 4, 5); delete[] credits; diff --git a/engines/kyra/staticres.cpp b/engines/kyra/staticres.cpp index bddeb758e0..395fe5d544 100644 --- a/engines/kyra/staticres.cpp +++ b/engines/kyra/staticres.cpp @@ -45,7 +45,7 @@ namespace Kyra { -#define RESFILE_VERSION 58 +#define RESFILE_VERSION 59 namespace { bool checkKyraDat(Common::SeekableReadStream *file) { @@ -469,6 +469,8 @@ bool StaticResource::init() { { kLolLightningDefs, kRawData, "MLGHTNG.DEF" }, { kLolFireballCoords, kLolRawDataBe16, "MFIREBLL.DEF" }, + { kLolCredits, kRawData, "LOLCREDITS" }, + { kLolHistory, kRawData, "HISTORY.FLS" }, { 0, 0, 0 } @@ -501,10 +503,10 @@ void StaticResource::deinit() { } const char * const *StaticResource::loadStrings(int id, int &strings) { - const char * const*temp = (const char* const *)getData(id, kStringList, strings); + const char * const *temp = (const char * const *)getData(id, kStringList, strings); if (temp) return temp; - return (const char* const *)getData(id, kLanguageList, strings); + return (const char * const *)getData(id, kLanguageList, strings); } const uint8 *StaticResource::loadRawData(int id, int &size) { diff --git a/tools/create_kyradat/create_kyradat.cpp b/tools/create_kyradat/create_kyradat.cpp index 1dff394d43..a739dda52e 100644 --- a/tools/create_kyradat/create_kyradat.cpp +++ b/tools/create_kyradat/create_kyradat.cpp @@ -37,7 +37,7 @@ #include "md5.h" enum { - kKyraDatVersion = 58, + kKyraDatVersion = 59, kIndexSize = 12 }; @@ -148,6 +148,8 @@ const ExtractFilename extractFilenames[] = { { kPaletteList31, kTypeRawData, "PALTABLE31.PAL" }, { kPaletteList32, kTypeRawData, "PALTABLE32.PAL" }, { kPaletteList33, kTypeRawData, "PALTABLE33.PAL" }, + + // CREDITS (used in FM-TOWNS and AMIGA) { kCreditsStrings, kTypeRawData, "CREDITS" }, // FM-TOWNS specific @@ -286,6 +288,8 @@ const ExtractFilename extractFilenames[] = { { kLolLightningDefs, kTypeRawData, "MLGHTNG.DEF" }, { kLolFireballCoords, kLolTypeRaw16, "MFIREBLL.DEF" }, + { kLolCredits, kTypeRawData, "LOLCREDITS" }, + { kLolHistory, kTypeRawData, "HISTORY.FLS" }, { -1, 0, 0 } diff --git a/tools/create_kyradat/create_kyradat.h b/tools/create_kyradat/create_kyradat.h index f15efcb5a4..69d82330ad 100644 --- a/tools/create_kyradat/create_kyradat.h +++ b/tools/create_kyradat/create_kyradat.h @@ -270,6 +270,8 @@ enum kExtractID { kLolLightningDefs, kLolFireballCoords, + kLolCredits, + kLolHistory, kMaxResIDs diff --git a/tools/create_kyradat/games.cpp b/tools/create_kyradat/games.cpp index a3413abd55..2788b2870b 100644 --- a/tools/create_kyradat/games.cpp +++ b/tools/create_kyradat/games.cpp @@ -105,7 +105,8 @@ const Game lolGames[] = { { kLol, DE_DEU, kPlatformPC, -1, "6b843869772c1b779e1386be868c15dd" }, // PC98 (no language specifc strings) - { kLol, JA_JPN, kPlatformPC98, -1, "6d5bd4a2f5ce433365734ca6b7a8d984" }, + { kLol, JA_JPN, kPlatformPC98, kFile1, "6d5bd4a2f5ce433365734ca6b7a8d984" }, + { kLol, JA_JPN, kPlatformPC98, kFile2, "1b0a457c48ae6908da301b656fe0aab4" }, // DOS CD (multi language version, with no language specific strings) { kLol, UNK_LANG, kPlatformPC, kTalkieFile1, "9d1778314de80598c0b0d032e2a1a1cf" }, @@ -660,7 +661,7 @@ const int lolFloppyNeed[] = { -1 }; -const int lolPC98Need[] = { +const int lolPC98File1Need[] = { kLolIngamePakFiles, kLolCharacterDefs, @@ -739,6 +740,12 @@ const int lolPC98Need[] = { -1 }; +const int lolPC98File2Need[] = { + kLolCredits, + + -1 +}; + const int lolCDFile1Need[] = { kLolHistory, -1 @@ -875,7 +882,8 @@ const GameNeed gameNeedTable[] = { { kKyra3, kPlatformPC, -1, kyra3Need }, { kLol, kPlatformPC, -1, lolFloppyNeed }, - { kLol, kPlatformPC98, -1, lolPC98Need }, + { kLol, kPlatformPC98, kFile1, lolPC98File1Need }, + { kLol, kPlatformPC98, kFile2, lolPC98File2Need }, { kLol, kPlatformPC, kTalkieFile1, lolCDFile1Need }, { kLol, kPlatformPC, kTalkieFile2, lolCDFile2Need }, diff --git a/tools/create_kyradat/tables.cpp b/tools/create_kyradat/tables.cpp index c8f3dcaec1..8eb2549a50 100644 --- a/tools/create_kyradat/tables.cpp +++ b/tools/create_kyradat/tables.cpp @@ -1656,6 +1656,12 @@ const ExtractEntrySearchData kLolFireballCoordsProvider[] = { EXTRACT_END_ENTRY }; +const ExtractEntrySearchData kLolCreditsProvider[] = { + { JA_JPN , kPlatformPC98, { 0x000005E7, 0x0001A1B0, { { 0x2A, 0xD0, 0x38, 0x84, 0x0C, 0x38, 0xCB, 0x52, 0x5D, 0x82, 0xBE, 0x03, 0x76, 0xFA, 0x0A, 0x4A } } } }, + + EXTRACT_END_ENTRY +}; + const ExtractEntrySearchData kLolHistoryProvider[] = { { UNK_LANG, kPlatformPC, { 0x000001D1, 0x00007F9B, { { 0x25, 0x10, 0x86, 0x40, 0xAC, 0x53, 0xFE, 0x11, 0x4D, 0xE2, 0xD9, 0x35, 0xD6, 0x89, 0xBB, 0x09 } } } }, @@ -1866,6 +1872,7 @@ const ExtractEntry extractProviders[] = { { kLolHealShapeFrames, kLolHealShapeFramesProvider }, { kLolLightningDefs, kLolLightningDefsProvider }, { kLolFireballCoords, kLolFireballCoordsProvider }, + { kLolCredits, kLolCreditsProvider }, { kLolHistory, kLolHistoryProvider }, { -1, NULL } }; |