aboutsummaryrefslogtreecommitdiff
path: root/engines/saga/saga.cpp
diff options
context:
space:
mode:
authorChristopher Page2008-07-01 03:01:11 +0000
committerChristopher Page2008-07-01 03:01:11 +0000
commit9c60fd183c8bc8f867a5dd5116c1195586342db6 (patch)
treede4ad9a356ea83bd9b009f1039b5fb21834ef890 /engines/saga/saga.cpp
parent563e28b668a44e830c26702b21f1d75cccb6cf03 (diff)
downloadscummvm-rg350-9c60fd183c8bc8f867a5dd5116c1195586342db6.tar.gz
scummvm-rg350-9c60fd183c8bc8f867a5dd5116c1195586342db6.tar.bz2
scummvm-rg350-9c60fd183c8bc8f867a5dd5116c1195586342db6.zip
Sound settings for Saga can be configured from the GMM
svn-id: r32863
Diffstat (limited to 'engines/saga/saga.cpp')
-rw-r--r--engines/saga/saga.cpp28
1 files changed, 17 insertions, 11 deletions
diff --git a/engines/saga/saga.cpp b/engines/saga/saga.cpp
index 4f48d1b26e..f912ffa93b 100644
--- a/engines/saga/saga.cpp
+++ b/engines/saga/saga.cpp
@@ -193,14 +193,9 @@ int SagaEngine::init() {
if (native_mt32)
_driver->property(MidiDriver::PROP_CHANNEL_MASK, 0x03FE);
- _music = new Music(this, _mixer, _driver, _musicVolume);
+ _music = new Music(this, _mixer, _driver);
_music->setNativeMT32(native_mt32);
_music->setAdlib(adlib);
-
- if (!_musicVolume) {
- debug(1, "Music disabled.");
- }
-
_render = new Render(this, _system);
if (!_render->initialized()) {
return FAILURE;
@@ -208,14 +203,11 @@ int SagaEngine::init() {
// Initialize system specific sound
_sound = new Sound(this, _mixer, _soundVolume);
- if (!_soundVolume) {
- debug(1, "Sound disabled.");
- }
-
+
_interface->converseInit();
_script->setVerb(_script->getVerbType(kVerbWalkTo));
- _music->setVolume(-1, 1);
+ _music->setVolume(_musicVolume, 1);
_gfx->initPalette();
@@ -519,4 +511,18 @@ int SagaEngine::getTalkspeed() {
return (ConfMan.getInt("talkspeed") * 3 + 255 / 2) / 255;
}
+void SagaEngine::syncSoundSettings() {
+ _soundVolume = ConfMan.getInt("sfx_volume");
+ _musicVolume = ConfMan.getInt("music_volume");
+ _subtitlesEnabled = ConfMan.getBool("subtitles");
+ _readingSpeed = getTalkspeed();
+
+ if (_readingSpeed > 3)
+ _readingSpeed = 0;
+
+ _music->setVolume(_musicVolume, 1);
+ _sound->setVolume(_soundVolume);
+
+}
+
} // End of namespace Saga