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.

0 votes
I'm new to C# and was looking to trigger an event on object b after a different event completes on object A. Like an explosion sound triggering on a cube after a line of dialog on a player. Any help would be appreciated!

 

I
in General Discussion by Chris F. (100 points)

2 Answers

0 votes
I would also like to know how this works. Please let me know if you have figured this out!
by Aaron I. (220 points)
0 votes
Something like this could work for you:

public void EventWithCallback(string eventName)

{

AkSoundEngine.PostEvent(eventName, gameObject, (uint)AkCallbackType.AK_EndOfEvent, EventCallback, this);

}

 

private void EventCallback(object in_cookie, AkCallbackType in_type, object in_callbackInfo)

{

if (in_type == AkCallbackType.AK_EndOfEvent)

{

// trigger second event here

}

}
by Alexander H. (300 points)
...