diff options
author | Max Horn | 2004-03-31 18:00:46 +0000 |
---|---|---|
committer | Max Horn | 2004-03-31 18:00:46 +0000 |
commit | b6a4610a778e100ed0186ef702bb880ccaab2dbc (patch) | |
tree | dfdec5ab50996645c2da18fa7894690c14ee7f4b /sword1 | |
parent | 933aab310067499f96c6e5bc3fb64f1af081707e (diff) | |
download | scummvm-rg350-b6a4610a778e100ed0186ef702bb880ccaab2dbc.tar.gz scummvm-rg350-b6a4610a778e100ed0186ef702bb880ccaab2dbc.tar.bz2 scummvm-rg350-b6a4610a778e100ed0186ef702bb880ccaab2dbc.zip |
be tolerant against abuse of ConfMan.getInt(); add missing default value for 'speech_volume' in bs1
svn-id: r13435
Diffstat (limited to 'sword1')
-rw-r--r-- | sword1/sword1.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sword1/sword1.cpp b/sword1/sword1.cpp index 6fd61ad66f..ac5b8d95f8 100644 --- a/sword1/sword1.cpp +++ b/sword1/sword1.cpp @@ -113,18 +113,19 @@ void SwordEngine::initialize(void) { _logic = new Logic(_objectMan, _resMan, _screen, _mouse, _sound, _music, _menu, _system, _mixer); _mouse->useLogicAndMenu(_logic, _menu); + ConfMan.registerDefault("speech_volume", 192); + uint8 musicVol = (uint8)ConfMan.getInt("music_volume"); uint8 speechVol = (uint8)ConfMan.getInt("speech_volume"); uint8 sfxVol = (uint8)ConfMan.getInt("sfx_volume"); - if (!speechVol) - speechVol = 192; _music->setVolume(musicVol, musicVol); // these routines expect left and right volume, _sound->setSpeechVol(speechVol, speechVol); // but our config manager doesn't support it. _sound->setSfxVol(sfxVol, sfxVol); - _systemVars.justRestoredGame = _systemVars.currentCD = - _systemVars.gamePaused = 0; + _systemVars.justRestoredGame = 0; + _systemVars.currentCD = 0; + _systemVars.gamePaused = 0; _systemVars.deathScreenFlag = 3; _systemVars.forceRestart = false; _systemVars.wantFade = true; |