aboutsummaryrefslogtreecommitdiff
path: root/simon
diff options
context:
space:
mode:
authorTorbjörn Andersson2003-08-30 20:14:30 +0000
committerTorbjörn Andersson2003-08-30 20:14:30 +0000
commite7bebcf7aa718631159f0bb21ccd99d53f076c37 (patch)
tree818ebc4213830b0b6437b30eb57a50d78910f323 /simon
parentbfee72f75716917bf1444e501909353a84750b22 (diff)
downloadscummvm-rg350-e7bebcf7aa718631159f0bb21ccd99d53f076c37.tar.gz
scummvm-rg350-e7bebcf7aa718631159f0bb21ccd99d53f076c37.tar.bz2
scummvm-rg350-e7bebcf7aa718631159f0bb21ccd99d53f076c37.zip
Fixed Simon 2 intro regression (and possibly others as well) caused by
recent mixer change. svn-id: r9926
Diffstat (limited to 'simon')
-rw-r--r--simon/sound.cpp10
-rw-r--r--simon/vga.cpp4
2 files changed, 7 insertions, 7 deletions
diff --git a/simon/sound.cpp b/simon/sound.cpp
index 2aca4b955c..c9381d66bd 100644
--- a/simon/sound.cpp
+++ b/simon/sound.cpp
@@ -270,9 +270,9 @@ SimonSound::SimonSound(const byte game, const GameSpecificSettings *gss, const c
_filenums = 0;
_offsets = 0;
- _voice_handle = 0;
- _effects_handle = 0;
- _ambient_handle = 0;
+ _voice_handle = -1;
+ _effects_handle = -1;
+ _ambient_handle = -1;
_voice_file = false;
_ambient_playing = 0;
@@ -440,7 +440,7 @@ void SimonSound::playVoice(uint sound) {
if (!_voice)
return;
- if (_voice_handle)
+ if (_voice_handle != -1)
_mixer->stop(_voice_index);
_voice_index = _voice->playSound(sound, &_voice_handle, (_game == GAME_SIMON1CD32) ? 0 : SoundMixer::FLAG_UNSIGNED);
@@ -468,7 +468,7 @@ void SimonSound::playAmbient(uint sound) {
if (_ambient_paused)
return;
- if (_ambient_handle)
+ if (_ambient_handle != -1)
_mixer->stop(_ambient_index);
_ambient_index = _effects->playSound(sound, &_ambient_handle, SoundMixer::FLAG_LOOP|SoundMixer::FLAG_UNSIGNED);
diff --git a/simon/vga.cpp b/simon/vga.cpp
index 9d7fc54b4b..e48db0c6c7 100644
--- a/simon/vga.cpp
+++ b/simon/vga.cpp
@@ -1597,7 +1597,7 @@ void SimonEngine::vc_59() {
vc_kill_sprite(file, start);
} while (++start != end);
} else {
- if (_sound->_voice_handle == 0)
+ if (_sound->_voice_handle == -1)
vc_skip_next_instruction();
}
}
@@ -1775,7 +1775,7 @@ void SimonEngine::vc_63_palette_thing_2() {
void SimonEngine::vc_64_skip_if_no_speech() {
// Simon2
- if (_sound->_voice_handle == 0)
+ if (_sound->_voice_handle == -1)
vc_skip_next_instruction();
}