Strange sound bug regarding gunshots (fixed)

Started by Hoovytaurus, February 20, 2019, 01:52:13 AM

Previous topic - Next topic

Hoovytaurus

First off, let me mention that the mod in question is attached. It is very small and was made in about twenty minutes. (quick note: the 001 and 002 sounds are unused)

Right. I'm trying to make a CE-compatible gun, and that worked perfectly. Nothing about it is broken. Except the sound.

I have created my own SoundDefs for the main sound and tail sound. While they do play correctly, they only play sometimes. I'd love to elaborate but it really is "sometimes". In the first rendition of the mod, the tail sound played correctly every shot while the main sound played every second shot. Weird, but consistent. Now I've played around with the xml and it seems absolutely entirely random.

This is not a CE thing. I ported the same mod to vanilla functionality and the issue persists. It also can't be something wrong with my xmls, since they are completely copied from working vanilla SoundDefs. The strange part is that if I, say, switch the gun to Shot_AutoPistol, it works perfectly and the sound plays entirely correctly.

However, my sound using the exact same xml has major issues.

This has brought me to believe there is something with the files themselves. To fix that, I've tried stereo and mono .ogg and .wavs. It seems to make no difference.

So, I'm out of ideas, and I'd hate to end my modding career this soon. Does anybody have a clue?

EDIT: Turns out I was using a folderpath when I should've been using a clipPath. I don't know why it "worked" anyway but it seems to have fixed the whole thing.

[attachment deleted due to age]