set3DRolloffCallback not firing most of the time

Has anyone had any luck using System::set3DRolloffCallback? I’m working on sound for a 2D game and want the attenuation to be based on distance from the player but panning to be based on position on screen (e.g. the camera) for spatialized elements.

I only seem to get callbacks for scatterer instruments, though. None of my Studio events with spatializers receive callbacks. I would expect to receive a callback for any event with a spatializer effect on it. Any ideas what I’m doing wrong here?

System::set3DRolloffCallback is only used in the Core API, Events made in FMOD Studio will not be effected as they use a different spatializer.

The way to something similar in Studio would be to set the spatializer attenuation to “off” and override the gain with a parameter, like the Distance parameter.

Yeah, I figured after doing some more reading and research. Funny that it works for Scatterer instruments though.

I ended up working around it in a rather goofy way instead of modifying all my spatialized events. I placed the listener on the camera. Each frame, I move the emitters along the vector from their game object to the camera so the distance to the camera equals the game object’s distance to the player. This roughly preserves the panning relative to the camera while giving distance attenuation relative to the player. Hacky solution but seems to work for my purposes.

I would love if there was a cleaner way that didn’t involve this kludginess or manually creating and controlling a distance parameter on every spatialized object.