Wait for dialog line to be finished then trigger next one

I’m working on dialog. I would like a line of dialog to play, then the next line of dialog waits for the previous line to be completed, then plays. Right now I’m just doing playoneshot, and wait for x number of seconds, then trigger the next line. But I would rather have the lines of dialog trigger each other instead. Thanks

It would be better to create your own function to handle this situation.

Create the EventDescription of your dialogue event and use EventDescription::getInstanceCount() to see how many instances are playing. Once the number of instances reaches 0 then the instance of that event has finished and you can start your next one.

https://www.fmod.com/resources/documentation-api?page=content/generated/FMOD_Studio_EventDescription_GetInstanceCount.html#/

If you’re using Programmer Instruments, you can check for the callback of if the programmer sound has been destroyed or if the event has stopped in order to start the next one.

https://www.fmod.com/resources/documentation-api?page=content/generated/FMOD_STUDIO_EVENT_CALLBACK.html#/