Page 1 of 1

(done) Adding randomised weapon sounds

Posted: Wed Nov 28, 2018 12:34 pm
by Gambit37
I'd like the "swish" sound for some weapons to be pulled from a randomised bank of sounds, to add some variety.

I've tracked down the code for this, but it's within a really big function that I don't want to have to duplicate/override (line ~109 in method_physattack() in methods.lua).

Is there a clean way of overriding this sound function, so that it'll play a randomised sound from a defined table and then fall back to a single sound if there's no table defined? Similar to the way the "oofs" are handled...?

Re: Adding randomised weapon sounds

Posted: Wed Nov 28, 2018 1:37 pm
by Gambit37
Also probably need the same fix for other methods too, not just weapons. Spell casting, etc.