在 Audiokinetic 社区问答论坛上,用户可对 Wwise 和 Strata 相关问题进行提问和解答。如需从 Audiokinetic 技术支持团队获取答复,请务必使用技术支持申请单页面。

0 投票
Hello,

I want to wait the end of the event to unload a bank even if the gameobject is unload.

 and still play the sound at the last known position in the world and kill it after it reach its end.

Is this possible ?

 

Exemple :

 I have a breakable, who load is own sound bank and events.

 i throw it

The object reach the ground and break, I play an event, "play_object_break_sound"

the sound is cut because the object and thus the bank is unloaded.

I would like to unload the object but wait the end of the event to unload the bank

Is there a function to do this ?

Thanks
分类:General Discussion | 用户: Timothee P. (100 分)

1个回答

0 投票
So basically you're asking if there is a way to get the duration of an event?

If so you'll have to parse through the xml files. When generating banks be sure to check the "generate xml files" its under project settings>sound banks. Be sure to check "estimated duration".

 

An easier way is almost to create a function that is basically a timer (at least in UE4), that after it hits the ground you delay the unload of the bank after a few seconds.

 

-Rob
用户: Robert M. (4.6k 分)
Not exactly. There is a function to know if an event is finished.

I want to know if there is a way to keep the bank loaded (until the end of the event) even if the game object is killed. (the bank is loaded in the game object)
Or if the only way is to keep the game object alive until the end of my event. which is kind of an issue for my programmers.
Ahh ok,

I do know that there is an "end of event" function, where you can see when the end event has been fired. My programmers and I are working on that too. In theory maybe you could wait until that fires to unload the bank. Just a simple boolean to check if the sound has finished, if so then unload the bank. If not then wait until it does so.

"You should look into the AK_EndOfEvent callback. You can refer to the Wwise SDK documentation documentation for the AkCallback.h file."

Is what Benoit suggested awhile back.
...