3D Sound in Monkey

Monkey Forums/Monkey Programming/3D Sound in Monkey

Sammy(Posted 2013) [#1]
Is there a way to achieve this in Monkey? I dont see a PlaySound(sound, chan, x, y, z) in the mojo.audio module but could this be emulated via the SetChannelPan & SetChannelVolume commands?


Goodlookinguy(Posted 2013) [#2]
Yes it could be emulated using 3D vectors to calculate distance and such. I recommend you setup a whole audio control system for 3D though, otherwise you might run into problems some other 3D audio systems have had. Such as when something moves the audio stays in place. This was a very real bug from a AAA game that I can't remember the name of.


Sammy(Posted 2013) [#3]
Ok, thanks for the tips. I don't actually need more than 2 dimensions, even though its a 3D scene, so hopefully this will simplify the whole process.

I know OpenAL and SDL Mixer both have 3D sound functionality in their API's so I suppose the 3D part has not been added to Monkey for either cross-platform compatibility or simple because Mojo is a 2D API?