SCI32: Add support for Shivers interactive demo

Closes Trac#9745.
This commit is contained in:
Colin Snover 2017-05-01 12:30:02 -05:00
parent 6da5a175cb
commit b208c82494
2 changed files with 19 additions and 2 deletions

View file

@ -3992,14 +3992,21 @@ static const struct ADGameDescription SciGameDescriptions[] = {
AD_LISTEND}, AD_LISTEND},
Common::DE_DEU, Common::kPlatformWindows, ADGF_TESTING, GUIO_SHIVERS }, Common::DE_DEU, Common::kPlatformWindows, ADGF_TESTING, GUIO_SHIVERS },
// Shivers - English Windows Demo // Shivers - English Windows Non-interactive Demo
// Executable scanning reports "2.100.002" // Executable scanning reports "2.100.002"
{"shivers", "Demo", { {"shivers", "Non-interactive Demo", {
{"resmap.000", 0, "d9e0bc5eddefcbe47f528760085d8927", 1186}, {"resmap.000", 0, "d9e0bc5eddefcbe47f528760085d8927", 1186},
{"ressci.000", 0, "3a93c6340b54e07e65d0e5583354d186", 10505469}, {"ressci.000", 0, "3a93c6340b54e07e65d0e5583354d186", 10505469},
AD_LISTEND}, AD_LISTEND},
Common::EN_ANY, Common::kPlatformWindows, ADGF_DEMO | ADGF_TESTING, GUIO_SHIVERS }, Common::EN_ANY, Common::kPlatformWindows, ADGF_DEMO | ADGF_TESTING, GUIO_SHIVERS },
// Shivers - English Windows Interactive Demo (from bgK in bug report Trac#9745)
{"shivers", "Demo", {
{"resmap.000", 0, "58a20b0c839d31d56802ead6c8f953c4", 7069},
{"ressci.000", 0, "f9eb6338f658945feadd4d27e58bdb93", 37404155},
AD_LISTEND},
Common::EN_ANY, Common::kPlatformWindows, ADGF_DEMO | ADGF_TESTING, GUIO_SHIVERS },
#undef GUIO_SHIVERS_DEMO #undef GUIO_SHIVERS_DEMO
#undef GUIO_SHIVERS #undef GUIO_SHIVERS

View file

@ -1372,6 +1372,16 @@ void ResourceManager::processPatch(ResourceSource *source, ResourceType resource
ResourceId resId = ResourceId(resourceType, resourceNr, tuple); ResourceId resId = ResourceId(resourceType, resourceNr, tuple);
ResourceType checkForType = resourceType; ResourceType checkForType = resourceType;
// HACK: The SFX resource map patch in the Shivers interactive demo has
// broken offsets for some sounds; ignore it so that the correct map from
// RESSCI.000 will be used instead
if (g_sci->getGameId() == GID_SHIVERS && g_sci->isDemo() &&
resourceType == kResourceTypeMap && resourceNr == 65535) {
delete source;
return;
}
// base36 encoded patches (i.e. audio36 and sync36) have the same type as their non-base36 encoded counterparts // base36 encoded patches (i.e. audio36 and sync36) have the same type as their non-base36 encoded counterparts
if (checkForType == kResourceTypeAudio36) if (checkForType == kResourceTypeAudio36)
checkForType = kResourceTypeAudio; checkForType = kResourceTypeAudio;