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.

Help me understand GetState syntax in C#/Unity

+1 vote

Hi,

I'm futzing around with AkSoundEngine.GetState in Unity for interactive music.  MonoDevelop is showing me it takes the following parameters:

string in_pstrStateGroupName
uint out_rState

I tried AkSoundEngine.GetState("MyStateGroupName", "MyStateName"); and it's a big failure.  I'm not sure what to put as an int for the 2nd parameter...

anyone help?  Thanks!

asked Nov 13, 2015 in General Discussion by Adam C. (230 points)

1 Answer

0 votes

The right way is:

uint stateID;
AkSoundEngine.GetState("MyStateGroupName", out stateID);

Now I have another question: how do I get the state name using state ID?

answered May 12, 2020 by João B. (170 points)
...