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.

+1 vote

[Unity 2020.3.1f1] [Wwise 2021.1.1]

According to Wwise documentation (https://www.audiokinetic.com/library/edge/?source=Unity&id=unity_add_triggers.html) you can inherit from AkTriggerBase, and the subclass should appear in the "Trigger On" dropdown list in an AkEvent or AkAmbient.  However I'm not seeing my AkTriggerBase-derived class appear in the dropdown list.  

 

Here is my simple AkTriggerBase-derived class as an example:

public class TestAkTrigger : AkTriggerBase
{
    void Hit()
    {
        if (triggerDelegate != null) 
        {
            triggerDelegate(null);
        }
    }
}
in General Discussion by Taylor C. (150 points)

1 Answer

+2 votes
 
Best answer
Hi Taylor,

Where is the script located? In Wwise 2021.1 it needs to be located in the Wwise > MonoBehaviour > Runtime folder.
by Mads Maretty S. (Audiokinetic) (39.8k points)
selected by Taylor C.
This did the trick, thanks! I think that detail would be useful to include in the documentation that I linked in the question.
This really isn't an ideal solution. Having to add custom code to the wwise folder is kind of sketchy, especially when upgrading means replacing the entire folder.
...