]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Don't negate frags if automatically switched teams
authorMario <mario@smbclan.net>
Thu, 14 Apr 2016 06:48:22 +0000 (16:48 +1000)
committerMario <mario@smbclan.net>
Thu, 14 Apr 2016 06:48:22 +0000 (16:48 +1000)
qcsrc/server/g_damage.qc

index 86e260e9f9f5643a557a69c06b6c686698e46318..675b794ecdb902b73e018f3ccaad6356e4feeb42 100644 (file)
@@ -328,7 +328,8 @@ void Obituary(entity attacker, entity inflictor, entity targ, int deathtype)
                        return;
                }
                LogDeath("suicide", deathtype, targ, targ);
-               GiveFrags(attacker, targ, -1, deathtype);
+               if(deathtype != DEATH_AUTOTEAMCHANGE.m_id) // special case: don't negate frags if auto switched
+                       GiveFrags(attacker, targ, -1, deathtype);
        }
 
        // ======