]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Set health and armor explicitly when killing the player via team change or kill comma...
authorMario <mario@smbclan.net>
Sun, 17 Jun 2018 07:15:30 +0000 (17:15 +1000)
committerMario <mario@smbclan.net>
Sun, 17 Jun 2018 07:15:30 +0000 (17:15 +1000)
qcsrc/server/g_damage.qc

index bdbe77352a6f1264df9b72e32ed4c62e042c490e..2efe1475a69aa9cef99b6a7fe37e98cdca5173f9 100644 (file)
@@ -593,9 +593,9 @@ void Damage (entity targ, entity inflictor, entity attacker, float damage, int d
                // These are ALWAYS lethal
                // No damage modification here
                // Instead, prepare the victim for his death...
-               SetResourceAmount(targ, RESOURCE_ARMOR, 0);
+               SetResourceAmountExplicit(targ, RESOURCE_ARMOR, 0);
                targ.spawnshieldtime = 0;
-               SetResourceAmount(targ, RESOURCE_HEALTH, 0.9); // this is < 1
+               SetResourceAmountExplicit(targ, RESOURCE_HEALTH, 0.9); // this is < 1
                targ.flags -= targ.flags & FL_GODMODE;
                damage = 100000;
        }