Hey guys, I have used audio with mono game before.
When I have instances of many units playing the same sound, its like the sound waves overlap, and the volume jumps up…
To compensate, I have used a timer to ensure some delay between instances.
However, now I am working on a 2 player racing game, where sound needs to be accurate for each car, considering their own unique acceleration and so forth.
-So I need instances to overlap… While maintaining some control over the master output.
Since I plan to do the engine sound using a single “thud”, which will repeat in whatever tempo, should I count every active instance, and set the volume for each new one according to the number of instances?
Like (pseudo):
Play(engineSound, vol = 1f / (float)instances, pitch = acceleration)
instances++;
Or should I create a class for the thud sound, and handle each instance in a list?
Whatever I think of, it seems to leave one instance dominant, right? because they are fire and forget when it comes to volume.
Thoughts?