Sets the specific pitch for the direct logical sound. This only works for actual sound definitions.
One thing I found myself in need of recently is the ability to replace sounds, but they have different pitch elements which means A_StartSound will also need to be changed on the mod's side in order to reflect the update. AKA I'd have to replace the actor if I wanted to modify the sound's played pitch. And I'd rather not set up an elaborate system in ZScript as well that would act as a randomizer when this can suffice perfectly.
PitchSet overrides PitchShiftRange if the value > 0.0, and overridden by A_StartSound if the pitch parameter is > 0.0.
Example:
Code: Select all
Explo1 dsbarexp
Explo2 dsbarexp
Explo3 dsbarexp
Explo4 dsbarexp
$pitchset Explo1 1.25
$pitchset Explo2 1.5
$pitchset Explo3 0.75
$pitchset Explo4 0.5
$random Explo { Explo1 Explo2 Explo3 Explo4 }