]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Suppress warning in overkill+lms
authorTimePath <andrew.hardaker1995@gmail.com>
Thu, 24 Mar 2016 01:32:52 +0000 (12:32 +1100)
committerTimePath <andrew.hardaker1995@gmail.com>
Thu, 24 Mar 2016 01:32:52 +0000 (12:32 +1100)
qcsrc/common/mutators/mutator/overkill/overkill.qc

index 125025f205c40f8ce1908705ff831df50d18a252..45a7e77f3d21a002470f2c2bb84721f4ecb8eec1 100644 (file)
@@ -135,12 +135,14 @@ MUTATOR_HOOKFUNCTION(ok, PlayerDies)
        e.pickup_anyway = true;
        e.spawnfunc_checked = true;
        spawnfunc_item_armor_small(e);
-       e.movetype = MOVETYPE_TOSS;
-       e.gravity = 1;
-       e.reset = SUB_Remove;
-       setorigin(e, frag_target.origin + '0 0 32');
-       e.velocity = '0 0 200' + normalize(targ.origin - frag_target.origin) * 500;
-       SUB_SetFade(e, time + 5, 1);
+       if (!wasfreed(e)) { // might have been blocked by a mutator
+        e.movetype = MOVETYPE_TOSS;
+        e.gravity = 1;
+        e.reset = SUB_Remove;
+        setorigin(e, frag_target.origin + '0 0 32');
+        e.velocity = '0 0 200' + normalize(targ.origin - frag_target.origin) * 500;
+        SUB_SetFade(e, time + 5, 1);
+       }
 
        frag_target.ok_lastwep = PS(frag_target).m_switchweapon.m_id;