diff options
author | Filippos Karapetis | 2007-12-23 02:33:58 +0000 |
---|---|---|
committer | Filippos Karapetis | 2007-12-23 02:33:58 +0000 |
commit | 5b74b676ce35172cae45278a8e6008c0858bf4d4 (patch) | |
tree | 7af869a81bb2538ec02f5f16c5f3350203739759 /engines/saga/rscfile.cpp | |
parent | 275c91be33968f17bf1ad2cad2cccdece598ce98 (diff) | |
download | scummvm-rg350-5b74b676ce35172cae45278a8e6008c0858bf4d4.tar.gz scummvm-rg350-5b74b676ce35172cae45278a8e6008c0858bf4d4.tar.bz2 scummvm-rg350-5b74b676ce35172cae45278a8e6008c0858bf4d4.zip |
Disable voices when voice files do not exist (like the original interpreter does), instead of exiting with an error. This is necessary for devices with little space
svn-id: r29956
Diffstat (limited to 'engines/saga/rscfile.cpp')
-rw-r--r-- | engines/saga/rscfile.cpp | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/engines/saga/rscfile.cpp b/engines/saga/rscfile.cpp index a081b200a9..6f93c8016a 100644 --- a/engines/saga/rscfile.cpp +++ b/engines/saga/rscfile.cpp @@ -360,6 +360,8 @@ bool Resource::createContexts() { bool censoredVersion = false; uint16 voiceFileType = GAME_VOICEFILE; + _vm->_voiceFilesExist = true; + // If the Wyrmkeep credits file is found, set the Wyrmkeep version flag to true if (Common::File::exists("graphics/credit3n.dlt")) { _vm->_gf_wyrmkeep = true; @@ -459,6 +461,10 @@ bool Resource::createContexts() { } else { // No voice file found, don't add any file to the array voicesFileInArray = true; + warning("No voice file found, voices will be disabled"); + _vm->_voicesEnabled = false; + _vm->_subtitlesEnabled = true; + _vm->_voiceFilesExist = false; } } else { // If the voices file is not specified in the detector table, add it here @@ -494,6 +500,10 @@ bool Resource::createContexts() { } else { // No voice file found, don't add any file to the array voicesFileInArray = true; + warning("No voice file found, voices will be disabled"); + _vm->_voicesEnabled = false; + _vm->_subtitlesEnabled = true; + _vm->_voiceFilesExist = false; } } } @@ -554,9 +564,9 @@ bool Resource::createContexts() { } context->serial = 0; - // IHNM has serveral different voice files, so we need to allow + // IHNM has several different voice files, so we need to allow // multiple resource contexts of the same type. We tell them - // apart by assigning each of the duplicates an unique serial + // apart by assigning each of the duplicates a unique serial // number. The default behaviour when requesting a context will // be to look for serial number 0. |