set snd_softclip 1
set snd_maxchannelvolume 0
set snd_streaming_length 2
-seta menu_snd_sliderscale 0 "0: decibels; 1: linear percent; 2: 0..10 scale"
+seta menu_snd_sliderscale 0 "0: decibels; 1: linear percent; 2: 0..10 scale; 3: slider size percent"
seta menu_snd_attenuation_method 1 "Use exponential instead of linear falloff for sound attenuation"
alias snd_attenuation_method_0 "set menu_snd_attenuation_method 0; set snd_soundradius 1200; set snd_attenuation_exponent 1; set snd_attenuation_decibel 0" // Quake default
alias snd_attenuation_method_1 "set menu_snd_attenuation_method 1; set snd_soundradius 2400; set snd_attenuation_exponent 4; set snd_attenuation_decibel 0" // nice approximation for method 2
return CTX(_("VOL^MAX"));
else if(v <= me.valueMin)
return CTX(_("VOL^OFF"));
+ else if(autocvar_menu_snd_sliderscale == 3) // fake percent scale
+ return sprintf(_("%d %%"), (v - me.valueMin) / (me.valueMax - me.valueMin) * 100);
else if(autocvar_menu_snd_sliderscale == 2) // 0..10 scale
return sprintf(_("%.1f"), (v - me.valueMin) / (me.valueMax - me.valueMin) * 10);
- else if(autocvar_menu_snd_sliderscale == 1) // percent scale
- return sprintf(_("%.2f %%"), fromDecibelOfSquare(v, me.valueMin));
+ else if(autocvar_menu_snd_sliderscale == 1) // real percent scale
+ return sprintf(_("%.2f %%"), fromDecibelOfSquare(v, me.valueMin) * 100);
else // decibel scale
return sprintf(_("%s dB"), ftos_decimals(toDecibelOfSquare(fromDecibelOfSquare(v, me.valueMin), 0), me.valueDigits));
}