aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/tinsel/music.cpp12
-rw-r--r--engines/tinsel/sound.cpp8
-rw-r--r--engines/tinsel/tinsel.cpp6
3 files changed, 21 insertions, 5 deletions
diff --git a/engines/tinsel/music.cpp b/engines/tinsel/music.cpp
index ea34fa963a..9560624e05 100644
--- a/engines/tinsel/music.cpp
+++ b/engines/tinsel/music.cpp
@@ -158,7 +158,11 @@ bool PlayMidiSequence(uint32 dwFileOffset, bool bLoop) {
if (TinselV1PSX) return false;
if (_vm->_config->_musicVolume != 0) {
- SetMidiVolume(_vm->_config->_musicVolume);
+ bool mute = false;
+ if (ConfMan.hasKey("mute"))
+ mute = ConfMan.getBool("mute");
+
+ SetMidiVolume(mute ? 0 : _vm->_config->_musicVolume);
}
// the index and length of the last tune loaded
@@ -967,8 +971,12 @@ void RestoreMidiFacts(SCNHANDLE Midi, bool Loop) {
currentLoop = Loop;
if (_vm->_config->_musicVolume != 0 && Loop) {
+ bool mute = false;
+ if (ConfMan.hasKey("mute"))
+ mute = ConfMan.getBool("mute");
+
PlayMidiSequence(currentMidi, true);
- SetMidiVolume(_vm->_config->_musicVolume);
+ SetMidiVolume(mute ? 0 : _vm->_config->_musicVolume);
}
}
diff --git a/engines/tinsel/sound.cpp b/engines/tinsel/sound.cpp
index d97137d3ef..6e8e736e14 100644
--- a/engines/tinsel/sound.cpp
+++ b/engines/tinsel/sound.cpp
@@ -129,9 +129,13 @@ bool SoundManager::playSample(int id, Audio::Mixer::SoundType type, Audio::Sound
error(FILE_IS_CORRUPT, _vm->getSampleFile(sampleLanguage));
// FIXME: Should set this in a different place ;)
- _vm->_mixer->setVolumeForSoundType(Audio::Mixer::kSFXSoundType, _vm->_config->_soundVolume);
+ bool mute = false;
+ if (ConfMan.hasKey("mute"))
+ mute = ConfMan.getBool("mute");
+
+ _vm->_mixer->setVolumeForSoundType(Audio::Mixer::kSFXSoundType, mute ? 0 : _vm->_config->_soundVolume);
//_vm->_mixer->setVolumeForSoundType(Audio::Mixer::kMusicSoundType, soundVolumeMusic);
- _vm->_mixer->setVolumeForSoundType(Audio::Mixer::kSpeechSoundType, _vm->_config->_voiceVolume);
+ _vm->_mixer->setVolumeForSoundType(Audio::Mixer::kSpeechSoundType, mute ? 0 : _vm->_config->_voiceVolume);
Audio::AudioStream *sampleStream = 0;
diff --git a/engines/tinsel/tinsel.cpp b/engines/tinsel/tinsel.cpp
index 248c97e209..702606e84b 100644
--- a/engines/tinsel/tinsel.cpp
+++ b/engines/tinsel/tinsel.cpp
@@ -1169,7 +1169,11 @@ void TinselEngine::RestartDrivers() {
}
// Set midi volume
- SetMidiVolume(_vm->_config->_musicVolume);
+ bool mute = false;
+ if (ConfMan.hasKey("mute"))
+ mute = ConfMan.getBool("mute");
+
+ SetMidiVolume(mute ? 0 : _vm->_config->_musicVolume);
}
/**