I’m using Fmod Ex and Fmod Designer v4.04.27 (didn’t switch to .29 because of need to add project path to all events that are retreived by name).
What I need is to setup an event so that only one of sound samples assigned to it is played a time (When asked to play another instance of event I want it not to be played).
If "max playbacks" is set to 1 and "max playbacks behavior" is set to "Just fail", getEventByIndex() always returns FMOD_OK, sets Event handle to new value and state of this event is always EVENT_STATE_READY.
This seems to be a bug.
Or maybe there is another way to achieve required behavior?
- Kamaitati asked 11 years ago
Let me explain more detailed.
I have an event in Designer that has [b:9s7ry4c8]max playbacks[/b:9s7ry4c8] = 1 and [b:9s7ry4c8]max playbacks behavior[/b:9s7ry4c8] set to [b:9s7ry4c8]Just fail[/b:9s7ry4c8]. It can play one of 4 different sound samples. This event is triggered from the game and I want it not to be played if it is already playing at that moment. So I think [b:9s7ry4c8]getEventByIndex()[/b:9s7ry4c8] should not return [b:9s7ry4c8]FMOD_OK[/b:9s7ry4c8] if I hear this event currently playing. But it returns [b:9s7ry4c8]FMOD_OK[/b:9s7ry4c8], sets Event* parameter to new handle value and only when I call [b:9s7ry4c8]start[/b:9s7ry4c8] for this new event, sound sample that was played tor event is stopped and new sound is started.
This means [b:9s7ry4c8]max playbacks[/b:9s7ry4c8] = 1 works, but [b:9s7ry4c8]Just fail[/b:9s7ry4c8] behavior doesn’t.
If it helps I can make a sample to expose this wrong behavior.
- Kamaitati answered 11 years ago
Please login first to submit.