Shipping build issues -> Infinite loop random end, Programmer sounds cut

Hello,

after we shipped our game (UE 4 4.22.3 / FMOD Studio 2.00.05), we are experiencing weird issues, which I can’t replicate in the editor.

  1. I have an ambient event (nature), which is basically a loop constructed from a nested event with basic ambient and some scatterer sounds and it loops infinitely unless there is a daytime change. This works nice in the editor, but in the shipping build (and it’s apparent from the live-streams I can observe), it randomly just ends. There’s no reason for it, because the loop, which might be 2 minutes long goes on for maybe half an hour, and then suddenly stops. I tried to replicate this in the editor and let the loop play for 2 hours and it doesn’t happen. However in shipping build. this happens always sooner or later. If I send to this event parameter change, the loop suddenly starts again (it’s as if it switched to a “standby mode” for some reason). A loop is a 2D event, so no attenuation can be responsible.

  2. Another rather serious issue is, that I am using programmer sound for voiceovers. They work nice for most of the time, but they sometimes randomly get cut before the end. I have a hook in Unreal Engine for a moment when the sound stops playing and then I move on, so the cut itself is caused by the sound. I was researching this issue and my pure speculation is that the sound itself pretends to start right, but there is some weird latency going on, so while the Event itself starts and ends correctly, the voiceover itself is a bit shifted. Is there any way how to debug this?

Thanks a lot for any possible answers. It’s a bit of a mood-killer seeing this on the streams. :slight_smile:

Jan

If you record a profiler session using live update and check the API calls view, are there any API calls around the point where the event cuts out that might explain why this is happening?

It might also be worth setting the event’s priority property to a higher value than the default. If this fixes your problem, it suggests that the event instance is being stolen at a point when a very large number of event instances are playing.

Again, try using live update and recording a profiler session, then look at the API calls recorded during that profiler session.

Since you mention the voice samples are being “shifted” by latency at the beginning of the event instance, it’s possible that they’re not being loaded far enough in advance of being played to start immediately that the event does. Try setting them to stream, or calling System::createSound in advance of playing the programmer instrument to give the asset time to load into memory.

Thank you very much for your responses. I have further questions:

  1. FMOD studio is unable to connect to shipping build with a profiler. Is there any trick for that?

  2. I am using programmer sounds for voiceovers. Unlike with normal events, I don’t see an option for setting them to stream.

Thanks!

Jan

To connect to your game with live update your game’s code must set the FMOD_STUDIO_INIT_LIVEUPDATE flag when calling Studio::System::initialize , and you must connect to the game over the network using FMOD Studio.

For more information about the FMOD_STUDIO_INIT_LIVEUPDATE flag, see Studio::System::initialize and FMOD_STUDIO_INITFLAGS in the FMOD API Documentation.

If your programmer instruments’ audio assets are stored in an audio table, you can set that audio table’s advanced loading mode to “stream” in the banks browser. If you would prefer not to set your audio table’s advanced loading mode, assets in that audio table will use the default loading mode specified in the default encoding settings for the platform, which you can view and change in the “build” tab of FMOD Studio’s preferences dialog.

If your project’s assets are stored loose on the drive rather than in a bank, you can make them stream in your game’s code by calling System::createSound with the FMOD_CREATESTREAM flag.