You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-05 12:10:55 +00:00
Rename voice_set_volume argument to p_volume to avoid confusion
This argument is indeed expected to be a volume on a linear scale (not dB), typically from 0.0 to 1.0, though it can go higher than 1.0.
This commit is contained in:
@@ -259,12 +259,12 @@ void AudioServerJavascript::voice_play(RID p_voice, RID p_sample){
|
||||
voice->active=true;
|
||||
}
|
||||
|
||||
void AudioServerJavascript::voice_set_volume(RID p_voice, float p_gain){
|
||||
void AudioServerJavascript::voice_set_volume(RID p_voice, float p_volume){
|
||||
|
||||
Voice* voice=voice_owner.get(p_voice);
|
||||
ERR_FAIL_COND(!voice);
|
||||
|
||||
voice->volume=p_gain;
|
||||
voice->volume=p_volume;
|
||||
|
||||
if (voice->active) {
|
||||
EM_ASM_( {
|
||||
|
||||
Reference in New Issue
Block a user