Community Q&A

Welcome to Audiokinetic’s community-driven Q&A forum. This is the place where Wwise and Strata users help each other out. For direct help from our team, please use the Support Tickets page. To report a bug, use the Bug Report option in the Audiokinetic Launcher. (Note that Bug Reports submitted to the Q&A forum will be rejected. Using our dedicated Bug Report system ensures your report is seen by the right people and has the best chance of being fixed.)

To get the best answers quickly, follow these tips when posting a question:

  • Be Specific: What are you trying to achieve, or what specific issue are you running into?
  • Include Key Details: Include details like your Wwise and game engine versions, operating system, etc.
  • Explain What You've Tried: Let others know what troubleshooting steps you've already taken.
  • Focus on the Facts: Describe the technical facts of your issue. Focusing on the problem helps others find a solution quickly.

+2 votes

int32 UAkComponent::PostAkEvent( class UAkAudioEvent * AkEvent, const FString& in_EventName )

{

return PostAkEventByName(GET_AK_EVENT_NAME(AkEvent, in_EventName));

}

This function has two parameters AkEvent and in_EventName. I don't understand it, whats the point of defining event string if you already gave event object to function, and viceversa?

in General Discussion by Nikola L. (140 points)
This is quite the discussion here at the moment. Anyone have any answers on this?
You can either pass the event using a pointer to a valid UAkAudioEvent instance, or it will read the event name from the second parameter and use that instead.

You only have to provide one parameter. Use either:

PostAkEvent(MyEvent, FString());

or:

PostAkEvent(nullptr, TEXT("My Event"))

It may be like this for backward compatibility reasons, not sure. It is definitely confusing.

1 Answer

–3 votes
Event Name is an OUT PARAMETER! it will give YOU the Event Name you dont need to submit the FString
by Alexis S. (90 points)
You are incorrect. The string is passed as a const ref. When you dig into what happens later, you'll discover both the event and the event name are passed into a GET_AK_EVENT_NAME macro which either extracts the name from the event pointer, or uses the fstring if the pointer is nullptr.
...