Sound bug with weapon fire in TGEA 1.7.1
by Dusty Monk · in Torque Game Engine · 07/08/2008 (1:21 pm) · 7 replies
I originally posted this over in the engine forum here,
www.garagegames.com/mg/forums/result.thread.php?qt=76824
but then not getting any love there, thought I might repost/bump here. Besides, this is obviously the more appropriate location.
Basically it appears that any sound over a few hundred milliseconds in length is getting clipped when used as a weapon fire sound in TGEA 1.7.1. For me, at least, this repro-ed with stock Stronghold. Replace the default crossbow fire sound with any 44 kHz sound that is like 1.5 secs in length. You'll see that the sound is immediately clipped upon playing. A few data points:
1.) I'm pretty sure this was working okay in TGEA 1.7.0.
2.) It's not all sounds. So far, just the sound associated with image state "fire". I suspect it's happens with any image state sound, but I haven't verified this.
If an associate or employee could at least verify this, it would be immensely appreciated. As of right now, I'm not sure if it's a new engine bug, or just something that's wonky with my audio drivers or devices.
Thanks,
Devon
www.garagegames.com/mg/forums/result.thread.php?qt=76824
but then not getting any love there, thought I might repost/bump here. Besides, this is obviously the more appropriate location.
Basically it appears that any sound over a few hundred milliseconds in length is getting clipped when used as a weapon fire sound in TGEA 1.7.1. For me, at least, this repro-ed with stock Stronghold. Replace the default crossbow fire sound with any 44 kHz sound that is like 1.5 secs in length. You'll see that the sound is immediately clipped upon playing. A few data points:
1.) I'm pretty sure this was working okay in TGEA 1.7.0.
2.) It's not all sounds. So far, just the sound associated with image state "fire". I suspect it's happens with any image state sound, but I haven't verified this.
If an associate or employee could at least verify this, it would be immensely appreciated. As of right now, I'm not sure if it's a new engine bug, or just something that's wonky with my audio drivers or devices.
Thanks,
Devon
About the author
Dusty Monk is founder and president of Windstorm Studios, an independant game studio. Formerly a sr. programmer at Ensemble Studios, Dusty has worked on AAA titles such as Age of Empires II & III, and Halo Wars.
#2
It would be really nice if though if we could get a fix.
Thanks for verifying it's not just me though, and for the suggestion.
Maybe we can convince Tom Spilman to take a look.. :D
07/10/2008 (1:02 pm)
Hmm. Well that's a serviceable workaround, and for now I can give that a shot. But all my sound data is stored in datablocks that initialize the image states upon load, and I really hate to break that code path. It would be really nice if though if we could get a fix.
Thanks for verifying it's not just me though, and for the suggestion.
Maybe we can convince Tom Spilman to take a look.. :D
#3
www.garagegames.com/mg/forums/result.area.php?qa=28
07/10/2008 (2:49 pm)
You may want to post TGEA bugs in the TGEA forums, you'll probably get better responsewww.garagegames.com/mg/forums/result.area.php?qa=28
#4
07/10/2008 (3:30 pm)
Wow thanks will do. I wasn't even aware those forums existed. They weren't showing up in my list, for some strange reason.
#5
07/11/2008 (6:05 am)
You need to edit your forum subscriptions. There's a link to do so on the main forums page in the upper left corner.
#6
07/11/2008 (8:19 am)
In ShapebaseImage.cpp there are 2 SFX_DELETE lines. Comment them both out. That fixed it for me.
#7
07/11/2008 (11:44 am)
Hey that fixed it! thanks!!
Associate Steve Acaster
[YorkshireRifles.com]
// Create our projectile %p = new (%this.projectileType)() { dataBlock = %projectile; initialVelocity = %velocity; initialPosition = %obj.getMuzzlePoint(%slot); sourceObject = %obj; sourceSlot = %slot; client = %obj.client; }; MissionCleanup.add(%p); //} [b]ServerPlay2D("carbineFireSound",%obj.getTransform()); //play fire sound [/b] return %p; }Your code might be a bit different from mine with bracket usage but that's the gist of it. When the projectile is created the sound plays.
Hacky, but a work-around.