Please be advised that the Audiokinetic offices will close at 5:00 p.m. EST on December 21st, 2018 for the holiday period, and will reopen on Thursday January 3rd, 2019 at 08:30 a.m. EST. Learn more.

Community Q&A

Where Wwise users help each other out!

Audiokinetic's Community Q&A is the forum where Wwise users ask and answer questions within the Wwise community. Contact Sales if your project requires a support plan.

Unity: Loading Banks and Playing Sound without Wwise Project

0 votes
Apologies if this has been definitively answered, but I've only seen some unsolved Qs through searching the website.

I want to provide team members with built banks without the need for them to have the entire Wwise project files. They will only be hearing the sound, not implementing. Those who need implementation power (using the picker, etc) I can provide the project. This is single platform Windows, and I've already exported the banks into the proper StreamingAssets folder within the unity project. However, I still (like others seemingly) get "Event Not Found" and bank loading errors from those who do not have the Wwise project.

Can we get a definitive answer on if this setup is possible, and if so, how? Thanks!
asked Apr 9 in General Discussion by Bob B. (130 points)
Hey Guys,
After digging into this issue a bit, I noticed it was an editor only problem and the issue seems to stem from line 94 of AkBasePathGetter.cs, if you change
        if (System.IO.Path.GetPathRoot(SoundBankDest) == "")
to
        if (SoundBankDest != "" && System.IO.Path.GetPathRoot(SoundBankDest) == "")

It seems to fix it.  Our issue stemed from SoundBankDest being empty string, and System.IO.Path.GetPathRoot throwing an exception on this causing the function to error out and not hit the backup soundbankdest string which points to where they actually are.  Hope this solves it.

4 Answers

0 votes
i'm guessing that you're trying to load the banks from the `GeneratedSoundbanks` directory that is only present with the project - can you confirm where you attempt to load banks from for clients who do not have the project data?
answered Apr 10 by Dan M. (360 points)
0 votes
This setup is definitely possible, it sounds like something might be off with the settings for where to load the soundbanks from, since only those that have the wwise project are able to correctly load the banks.

Make sure that you are loading the banks from the StreamingAssets folder.
answered Apr 10 by Kaan (260 points)
0 votes
 
Best answer

Hey Guys, 
After digging into this issue a bit, I noticed it was an editor only problem and the issue seems to stem from line 94 of AkBasePathGetter.cs, if you change
        if (System.IO.Path.GetPathRoot(SoundBankDest) == "")
to
        if (SoundBankDest != "" && System.IO.Path.GetPathRoot(SoundBankDest) == "")

It seems to fix it.  Our issue stemed from SoundBankDest being empty string, and System.IO.Path.GetPathRoot throwing an exception on this causing the function to error out and not hit the backup soundbankdest string which points to where they actually are.  Hope this solves it.

Already replied this but putting this as an actual answer

answered Apr 10 by Patrick W. (440 points)
selected Apr 13 by Bob B.
0 votes
Hi, I think that we were dealing with the same problem. It was caused by settings of Wwise in Unity. Since some recent patch, unity tries to generate sound banks itself before running the game (and it fails if it is not able to find the project folder). You can change this settings in Unity -> Edit -> Wwise Settings -> uncheck "Enable copying of soundbanks at pre-Build step".
answered Apr 13 by Radoslav K. (430 points)
...