diff options
author | sluicebox | 2020-01-07 02:13:55 -0800 |
---|---|---|
committer | sluicebox | 2020-01-07 02:25:49 -0800 |
commit | 09161504210d3a659f99d804b9a326fb441568bd (patch) | |
tree | ff4ecfcc31ee422137187e0674dd6a9ee3972698 /engines | |
parent | 6304e59a2b2dd3b2a61af5cdf496f0cc3221b910 (diff) | |
download | scummvm-rg350-09161504210d3a659f99d804b9a326fb441568bd.tar.gz scummvm-rg350-09161504210d3a659f99d804b9a326fb441568bd.tar.bz2 scummvm-rg350-09161504210d3a659f99d804b9a326fb441568bd.zip |
SCI32: Ignore invalid GK2 audio maps in all versions
Fixes #11014, #11270
Diffstat (limited to 'engines')
-rw-r--r-- | engines/sci/resource_audio.cpp | 41 |
1 files changed, 14 insertions, 27 deletions
diff --git a/engines/sci/resource_audio.cpp b/engines/sci/resource_audio.cpp index c825196d93..73e10eb1ee 100644 --- a/engines/sci/resource_audio.cpp +++ b/engines/sci/resource_audio.cpp @@ -513,36 +513,23 @@ int ResourceManager::readAudioMapSCI11(IntMapResourceSource *map) { continue; } + // GK2 has invalid audio36 map entries on CD 1 of the German + // version and CD 6 of all versions. All are safe to ignore + // because their content doesn't apply to the disc's chapter. if (g_sci->getGameId() == GID_GK2) { - // At least version 1.00 of the US release, and the German - // release, of GK2 have multiple invalid audio36 map entries on - // CD 6 - if (map->_volumeNumber == 6 && offset + syncSize >= srcSize) { - bool skip; - switch (g_sci->getLanguage()) { - case Common::EN_ANY: - skip = (map->_mapNumber == 22 || map->_mapNumber == 160); - break; - case Common::DE_DEU: - skip = (map->_mapNumber == 22); - break; - default: - skip = false; - } - - if (skip) { - continue; - } + // Map 2020 on CD 1 only exists in localized versions and + // contains inventory messages from later chapters. + if (map->_volumeNumber == 1 && + map->_mapNumber == 2020) { + continue; } - // Map 2020 on CD 1 of the German release of GK2 is invalid. - // This content does not appear to ever be used by the game (it - // does not even exist in the US release), and there is a - // correct copy of it on CD 6, so just ignore the bad copy on - // CD 1 - if (g_sci->getLanguage() == Common::DE_DEU && - map->_volumeNumber == 1 && - map->_mapNumber == 2020) { + // Maps 22 and 160 on CD 6 appear in various broken forms + // in English and apparently every localized version. + // These messages are for Grace's notebook and castle + // secret passage rooms which aren't in chapter 6. + if (map->_volumeNumber == 6 && + (map->_mapNumber == 22 || map->_mapNumber == 160)) { continue; } } |