]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/triggers/target/speaker.qc
Don't even try to translate keys if game isn't translated
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / triggers / target / speaker.qc
index dc9b34b4a95796fc575d4785c8cdaf4e68a83999..af327b443bc21febb1c8494829bfd10e1fb4543a 100644 (file)
@@ -1,3 +1,4 @@
+#include "speaker.qh"
 #ifdef SVQC
 // TODO add a way to do looped sounds with sound(); then complete this entity
 void target_speaker_use_off(entity this, entity actor, entity trigger);
@@ -115,17 +116,17 @@ spawnfunc(target_speaker)
        else if(this.spawnflags & 1) // LOOPED_ON
        {
                ambientsound (this.origin, this.noise, VOL_BASE * this.volume, this.atten);
-               remove(this);
+               delete(this);
        }
        else if(this.spawnflags & 2) // LOOPED_OFF
        {
-               objerror("This sound entity can never be activated");
+               objerror(this, "This sound entity can never be activated");
        }
        else
        {
                // Quake/Nexuiz fallback
                ambientsound (this.origin, this.noise, VOL_BASE * this.volume, this.atten);
-               remove(this);
+               delete(this);
        }
 }
 #endif