Audiokinetic's Community Q&A is the forum where users can ask and answer questions within the Wwise and Strata communities. If you would like to get an answer from Audiokinetic's Technical support team, make sure you use the Support Tickets page.

+5 votes
We switched our quite-large project to use event-based packaging. Unfortunately, it seems as if our media assets aren't always getting loaded. (We get many "Media was not loaded for this source" errors.) (That said, it sounds like the audio is playing, it's just complaining.)

The documentation says that referencing the event in a level will guarantee it's loaded. However, a lot of our audio events are properties of blueprints which may not be in a level at load time. They are on actors which are dynamically placed in world, or are part of data structures (for example, a table which maps audio events to special game events). Do we need to do something special to make sure that the media is loaded for the events that are not literally connected to a level?

We continue to investigate, but wondered if our usage model might by causing problems.
in General Discussion by Shannon P. (230 points)

4 Answers

0 votes
Curious if there was a resolution to this one.
by Bart K. (140 points)
We resolved this, but maybe not in a way that will be repeatable for you.

Firstly, we used the commandlet to do the migration. Which did do a lot of work, but it seemed incomplete. We ended up with old and new assets around for some reason and had to do a bunch of cleanup by hand.

But a larger problem was that we had already put stuff into soundbanks (before event-based packagin existed). We didn't remove those soundbanks before doing the migrate, so they also got migrated. Which sort of defeats the purpose of the event based packaging. So, we unbanked everything. This is painful because every AkEvent asset has its bank stored in it, so one needs to modify all the events. (We used the matrix editor to do this. It's not hard, but there are a lot of files to check out/in for a large project like ours.) This seemed to fix a lot of the loading issues, but we still sometimes had sounds fail to play.

To "fix" that, basically, we cleared the sound cache and forced asset syncing several times and in various orders and combinations. Eventually, it seemed to work.

Sorry that we never found the main culprit. I think it was a combination of the soundbanks existing ahead of time, and the commandlet not working 100%.
We had this error a great deal with our VO.  In our case it turned out to be because the InitBank->DefaultLanguage was blank.  I changed FAkAudioDevice::GetDefaultLanguage() to this:

FString FAkAudioDevice::GetDefaultLanguage() const
{
    if (InitBank && !InitBank->DefaultLanguage.IsEmpty())
    {
        return InitBank->DefaultLanguage;
    }

    return TEXT("English(US)");
}
There's an issue with "Generate Sound Data" Unreal integration feature. It's supposed to initialize the "Platform Asset Data" for each event, but for us it doesn't seem to do that anymore. I've had more luck with the GenerateSoundBanks Commandlet.
This is happening more and more, Audiokinetic should solve this issue
0 votes
I have resolved this error by performing Clear Sound Data -> Force Asset Synchronization (more than once) -> Generate Sound Data.

Need to check Clear data in Assets and Clear orphaned Unreal Wwise Media Assets.

You can have a try. :-)
by MR H. (290 points)
0 votes

Nearly a year later, but all of my research (spent a whole day experimenting and googling everything imaginable) leads me to conclude that Event Based Packaging is (still) totally unreliable and unusable as of this writing. Turn it off in Unreal Project Settings, go back to the old Soundbanks workflow, hopefully AK will keep working on it because it sounds like a better system overall. ***EDIT*** I can confirm what Shannon P said. This appears to be a bug in EBP caused by using Soundbanks. We solved it by deleting all Soundbanks in Wwise, then going into Unreal and bulk editing all AK Event uassets to remove any references to Soundbanks. After that we cleaned up a few Soundbank uasset files that were no longer in use but not cleaned up by Wwise's delete cache options.

by Kyle W. (290 points)
edited by Kyle W.
0 votes
I'm new with Unreal and Wwise to be honest, but in my first project I used Event-Based Packaging and everything worked perfect until it dosen't. I started to have problemes with switch containers folders, for some reason the error "media was not loaded for this source" start appearing. In the editor everything sounded perfect but when I packaged, all files related with those switch containers wont load... . Finally I turned off "Event-Base Packaging" and the problem was gone, all files loaded, the builds sounded great.

I'm sure I'm missing something, EBP its three years old now and it is so powerfull, but it doesn't worked for me. I wish I can talk with people that have entire games launched with EBP :(
by David T. (190 points)
...