X-Git-Url: https://de.git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fclient%2Ftarget_music.qc;h=5703c146d21703d650638a7d42277c7a9f3fdfc6;hb=2a9df1dc726597e8943be9ef956620c36693d219;hp=a7a46d80ad5788c19e58e649c7d25c0a147b1376;hpb=07cf7fb3bfa35c5a2792fe36be6f1c22dcd7371c;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/client/target_music.qc b/qcsrc/client/target_music.qc index a7a46d80a..5703c146d 100644 --- a/qcsrc/client/target_music.qc +++ b/qcsrc/client/target_music.qc @@ -39,7 +39,7 @@ void TargetMusic_Advance() else e.state = 0; } - vol = e.state * e.volume * cvar("bgmvolume"); + vol = e.state * e.volume * autocvar_bgmvolume; if(vol != vol0) { if(vol0 < 0) @@ -50,6 +50,11 @@ void TargetMusic_Advance() } } music_trigger = world; + + if(best) + bgmtime = getsoundtime(best, CHAN_VOICE); + else + bgmtime = gettime(GETTIME_CDTRACK); } void Net_TargetMusic()