mirror of
https://github.com/libretro/scummvm.git
synced 2025-02-21 03:31:40 +00:00
added function to interrupt voice
svn-id: r5869
This commit is contained in:
parent
ba0abd27d7
commit
0ecd439fe1
@ -117,7 +117,7 @@ void SimonSound::playVoice(uint sound)
|
||||
if (!_voice)
|
||||
return;
|
||||
|
||||
_voice->playSound(sound, &_voice_handle);
|
||||
_voice_index = _voice->playSound(sound, &_voice_handle);
|
||||
}
|
||||
|
||||
void SimonSound::playEffects(uint sound)
|
||||
@ -155,6 +155,11 @@ bool SimonSound::hasVoice()
|
||||
return _voice != NULL;
|
||||
}
|
||||
|
||||
void SimonSound::stopVoice()
|
||||
{
|
||||
_mixer->stop(_voice_index);
|
||||
}
|
||||
|
||||
void SimonSound::stopAll()
|
||||
{
|
||||
_mixer->stopAll();
|
||||
|
@ -52,6 +52,7 @@ private:
|
||||
};
|
||||
|
||||
byte _game;
|
||||
int _voice_index;
|
||||
int _ambient_index;
|
||||
SoundMixer *_mixer;
|
||||
|
||||
@ -78,6 +79,7 @@ public:
|
||||
void playAmbient(uint sound);
|
||||
|
||||
bool hasVoice();
|
||||
void stopVoice();
|
||||
void stopAll();
|
||||
void effectsPause(bool b);
|
||||
void ambientPause(bool b);
|
||||
|
Loading…
x
Reference in New Issue
Block a user