From 56ca87b3a573c64e8c82d9c6fa8427ddb5458ba5 Mon Sep 17 00:00:00 2001 From: Strangerke Date: Wed, 23 Jan 2013 01:42:31 +0100 Subject: HOPKINS: Modify misc setVolume functions so they are a bit less precise --- engines/hopkins/sound.cpp | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) (limited to 'engines/hopkins') diff --git a/engines/hopkins/sound.cpp b/engines/hopkins/sound.cpp index 3ef1618d8b..d24c3e10b2 100644 --- a/engines/hopkins/sound.cpp +++ b/engines/hopkins/sound.cpp @@ -630,19 +630,17 @@ void SoundManager::PLAY_SOUND2(const Common::String &file) { void SoundManager::MODSetSampleVolume() { for (int idx = 0; idx < SWAV_COUNT; ++idx) { - if (Swav[idx]._active) { - int volume = (idx == 20) ? (_voiceVolume * 255 / 16) : (_soundVolume * 255 / 16); + if (idx != 20 && Swav[idx]._active) { + int volume = _soundVolume * 255 / 16; _vm->_mixer->setChannelVolume(Swav[idx]._soundHandle, volume); } } } void SoundManager::MODSetVoiceVolume() { - for (int idx = 0; idx < SWAV_COUNT; ++idx) { - if (Swav[idx]._active) { - int volume = (idx == 20) ? (_voiceVolume * 255 / 16) : (_soundVolume * 255 / 16); - _vm->_mixer->setChannelVolume(Swav[idx]._soundHandle, volume); - } + if (Swav[20]._active) { + int volume = _voiceVolume * 255 / 16; + _vm->_mixer->setChannelVolume(Swav[20]._soundHandle, volume); } } -- cgit v1.2.3