add CVar to control footstep volume

This commit is contained in:
Ricardo Luís Vaz Silva 2024-10-20 22:17:16 -03:00
parent d07d08ce9f
commit d0e6bce4e6
2 changed files with 4 additions and 1 deletions

View file

@ -62,6 +62,9 @@ CUSTOM_CVAR(Int, snd_samplerate, 0, CVAR_ARCHIVE | CVAR_GLOBALCONFIG)
CVAR(Int, snd_buffersize, 0, CVAR_ARCHIVE | CVAR_GLOBALCONFIG)
CVAR(Int, snd_hrtf, -1, CVAR_ARCHIVE | CVAR_GLOBALCONFIG)
CVAR(Float, snd_footstepvolume, 1.f, CVAR_ARCHIVE|CVAR_GLOBALCONFIG)
#if !defined(NO_OPENAL)
#define DEF_BACKEND "openal"
#else

View file

@ -1754,7 +1754,7 @@ class PlayerPawn : Actor
if(Step)
{
A_StartSound(Step, flags: CHANF_OVERLAP, volume: Ground.StepVolume);
A_StartSound(Step, flags: CHANF_OVERLAP, volume: Ground.StepVolume * snd_footstepvolume);
}
//Steps make splashes regardless.