]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Fix "Adding score to unknown player!" warning
authorterencehill <piuntn@gmail.com>
Thu, 17 Jun 2021 13:21:40 +0000 (15:21 +0200)
committerterencehill <piuntn@gmail.com>
Thu, 17 Jun 2021 13:21:40 +0000 (15:21 +0200)
qcsrc/common/gamemodes/gamemode/lms/sv_lms.qc

index 1778e34be2959d4d03a044237164663dccb2c83c..9185525e72b213e1101a2d4b17af601f510876cb 100644 (file)
@@ -342,7 +342,8 @@ MUTATOR_HOOKFUNCTION(lms, Damage_Calculate)
        entity frag_target = M_ARGV(2, entity);
        float frag_damage = M_ARGV(4, float);
 
-       if (IS_PLAYER(frag_attacker) && !IS_DEAD(frag_target) && frag_attacker != frag_target)
+       if (IS_PLAYER(frag_attacker) && !IS_DEAD(frag_attacker)
+               && IS_PLAYER(frag_target) && !IS_DEAD(frag_target) && frag_attacker != frag_target)
        {
                float vampire_factor = 0;