hi folks, i perused the Unity threads and didn’t find what i’m looking for. i need a way to do the following:
play an event from a static 3D location by passing the location to the emitter. This is equivalent to AudioSource.PlayClipAtPoint(Vector3 location);
play an event from a moving 3D location by passing the game Object to the emitter. More like AudioSource.Play();
i do not want to put emitters on the source objects in the Hierarchy for this but would instead create objects with emitters in a dedicated scene for audio and would rather pass Vector 3 info to the Emitter if possible. alternately i could use the Studio Runtime Manager and pass position that way. i’m teaching FMOD and want to simplify the experience for them.
i looked into the Runtime Manager setup but it’s very confusing and seems to not work. here’s a quick example based on my understanding of how the Runtime Manager is called:
public void DartGunShoot(Vector3 location)
{
var studioSystem = FMODUnity.RuntimeManager.StudioSystem;
studioSystem.PlayOneShotAttached(dartGunShoot, location);
}
Mono Develop says that there is no method called PlayOneShotAttached and highlights it red.
dartGunShoot is the Event string and location is the passed Vector3. what am i doing wrong? i can’t call it by using public static void either. basically a C# example of this method in action would be fine. any help appreciated!