Game Development Community

Playing the same sound twice causes volume increase

by Philip Mansfield · in Torque Game Builder · 01/13/2006 (2:32 pm) · 1 replies

I've noticed this with other T2D projects that I've done, and I think it's about time I fixed it :)

If I have two (or more) instances of the same sound effect going off at the same time then the volume of that sound effect is amplified. If the sound effects have a bit of a gap between being triggered, then the problem isn't noticable.

I don't want to do a 'if sound is already playing, then don't play it again' solution as it means hitting two enemies in quick succession will cause the second one not to play a hit sound.

I'm currently using, 'if sound is playing, stop it and play a fresh version' but it causes a bit of clipping. I guess I need to do something with playing sounds on different channels, but I'm not really up on configuring the sound side of T2D.

If anyone has any advice, I'd appreciate it.

#1
01/14/2006 (5:11 am)
I'd say you're doing about as much as can be done. If you play 2 instances of the same sound at the same time, it's going to be louder no matter what (well, unless you do some kind of DSP compression or fiddle with the volume based on counting sounds being played, but...).