]> git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/mapobjects/trigger/multi.qc
Merge branch 'master' into bones_was_here/q3compat
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / mapobjects / trigger / multi.qc
index c087f071a3eeb2611713256f8e0429bfc59b0831..407a75371c54cd90529d33a4741a43b4eae6fe3e 100644 (file)
@@ -29,16 +29,7 @@ void multi_trigger(entity this)
                return; // only players
        }
 
-       // TODO: restructure this so that trigger_secret is more independent
-       if (this.classname == "trigger_secret")
-       {
-               if (!IS_PLAYER(this.enemy))
-                       return;
-               found_secrets = found_secrets + 1;
-               WriteByte (MSG_ALL, SVC_FOUNDSECRET);
-       }
-
-       if (this.noise)
+       if (this.noise && this.noise != "")
        {
                _sound (this.enemy, CH_TRIGGER, this.noise, VOL_BASE, ATTEN_NORM);
        }
@@ -167,7 +158,7 @@ spawnfunc(trigger_multiple)
        else if (this.sounds == 3)
                this.noise = "misc/trigger1.wav";
 
-       if(this.noise)
+       if(this.noise && this.noise != "")
                precache_sound(this.noise);
 
        if (!this.wait)
@@ -176,7 +167,7 @@ spawnfunc(trigger_multiple)
                this.wait = 0;
        this.use = multi_use;
 
-       if(this.wait == -1 && q3compat & BIT(1))
+       if(this.wait == -1 && (q3compat & BIT(1)))
                this.wait = 0.1; // compatibility for q3df: "instant" return
 
        EXACTTRIGGER_INIT;