Game Development Community

Sounds play... sometimes

by Jason McIntosh · in Torque Game Builder · 04/22/2006 (10:32 am) · 2 replies

I have weird behavior when playing some wav files. Some sounds play fine every time, and some sounds play only once in a while.

For example, a few of my interface sounds don't work 70% of the time (mouse over 10 times, and you'll hear a sound 3 times). I've tried to find some cause for this with the data, but I can't find any pattern. I changed code to see if that affected it, but no. Some sounds play every single time I call alxPlay(), and some don't.

This is driving me crazy. Has anyone else had this kind of problem, or is my copy of T2D haunted? I seriously considering using a 3rd party sound library.

Edit: this has been a problem since the first release of T2D, so it's not something the recent releases would be causing.

#1
04/22/2006 (11:12 am)
Is it more likely to be something to do with your wav file?

I've found that some wav files actually cause the engine to crash out when I try to play them. To fix that, I typically open the wav in the free SoundRecorder app that ships with Windows and just resave it.

The other option is try converting it to ogg format and see what happens.
#2
04/22/2006 (12:17 pm)
It must be an issue with Torque's audio implementation being very picky about the bitrate or something. Thanks for the reply. :)

Edit: I tried what you said, resaved the problem sounds using Recorder. Didn't change anything. :(