From af4727577f39720564b4339de267aa0aae7af4a5 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Mon, 5 Sep 2011 19:18:46 +0300 Subject: Fix multiply new message sounds at same time. --- src/resources/soundeffect.cpp | 2 +- src/resources/soundeffect.h | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'src/resources') diff --git a/src/resources/soundeffect.cpp b/src/resources/soundeffect.cpp index 49e7adc31..de11a8786 100644 --- a/src/resources/soundeffect.cpp +++ b/src/resources/soundeffect.cpp @@ -53,7 +53,7 @@ Resource *SoundEffect::load(void *buffer, unsigned bufferSize) } } -bool SoundEffect::play(int loops, int volume) +bool SoundEffect::play(int loops, int volume, int channel) { Mix_VolumeChunk(mChunk, volume); diff --git a/src/resources/soundeffect.h b/src/resources/soundeffect.h index 80f826646..fdd4bd275 100644 --- a/src/resources/soundeffect.h +++ b/src/resources/soundeffect.h @@ -54,11 +54,12 @@ class SoundEffect : public Resource * * @param loops Number of times to repeat the playback. * @param volume Sample playback volume. + * @param channel Sample playback channel. * * @return true if the playback started properly * false otherwise. */ - virtual bool play(int loops, int volume); + virtual bool play(int loops, int volume, int channel = -1); protected: /** -- cgit v1.2.3-70-g09d2