X-Git-Url: https://de.git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fcommon%2Ftriggers%2Ftarget%2Fspeaker.qc;h=75f733c09eefa44d420a36c894beb88dfa05b791;hb=96e1acc3050bcb718e2f06702e5b88a60459a015;hp=e0701dc14f3273487baec91a8d19543f0b1d1e08;hpb=c89dfaa4d0342b98c320621557973a65114fbdf4;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/common/triggers/target/speaker.qc b/qcsrc/common/triggers/target/speaker.qc index e0701dc14..75f733c09 100644 --- a/qcsrc/common/triggers/target/speaker.qc +++ b/qcsrc/common/triggers/target/speaker.qc @@ -10,9 +10,9 @@ void target_speaker_use_activator() { var .string sample = GetVoiceMessageSampleField(substring(self.noise, 1, -1)); if(GetPlayerSoundSampleField_notFound) - snd = "misc/null.wav"; + snd = SND(Null); else if(activator.(sample) == "") - snd = "misc/null.wav"; + snd = SND(Null); else { tokenize_console(activator.(sample)); @@ -36,9 +36,9 @@ void target_speaker_use_on() { var .string sample = GetVoiceMessageSampleField(substring(self.noise, 1, -1)); if(GetPlayerSoundSampleField_notFound) - snd = "misc/null.wav"; + snd = SND(Null); else if(activator.(sample) == "") - snd = "misc/null.wav"; + snd = SND(Null); else { tokenize_console(activator.(sample)); @@ -52,13 +52,13 @@ void target_speaker_use_on() } else snd = self.noise; - sound(self, CH_TRIGGER_SINGLE, snd, VOL_BASE * self.volume, self.atten); + _sound(self, CH_TRIGGER_SINGLE, snd, VOL_BASE * self.volume, self.atten); if(self.spawnflags & 3) self.use = target_speaker_use_off; } void target_speaker_use_off() {SELFPARAM(); - sound(self, CH_TRIGGER_SINGLE, "misc/null.wav", VOL_BASE * self.volume, self.atten); + sound(self, CH_TRIGGER_SINGLE, SND_Null, VOL_BASE * self.volume, self.atten); self.use = target_speaker_use_on; } void target_speaker_reset()