]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/turrets/targettrigger.qc
Merge branch 'master' into Mario/fullbright_skins
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / turrets / targettrigger.qc
index 01dced5f3c403f0ec3af2ad263290d7ba64186c1..15dbaec4f009b0c8d87fba54e6c0269c72f41709 100644 (file)
@@ -1,13 +1,13 @@
 spawnfunc(turret_targettrigger);
-void turret_targettrigger_touch();
+void turret_targettrigger_touch(entity this);
 
-void turret_targettrigger_touch()
-{SELFPARAM();
+void turret_targettrigger_touch(entity this)
+{
     if (this.cnt > time) return;
     FOREACH_ENTITY_STRING_ORDERED(targetname, this.target, {
         if (!(it.turret_flags & TUR_FLAG_RECIEVETARGETS)) continue;
         if (!it.turret_addtarget) continue;
-        WITHSELF(it, it.turret_addtarget(other, this));
+        it.turret_addtarget(it, other, this);
     });
     this.cnt = time + 0.5;
 }
@@ -18,7 +18,7 @@ spawnfunc(turret_targettrigger)
 {
     if(!autocvar_g_turrets) { remove(this); return; }
 
-    WITHSELF(this, InitTrigger());
+    InitTrigger(this);
 
     settouch(this, turret_targettrigger_touch);
 }