]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Minor performance improvement
authorMario <mario@smbclan.net>
Thu, 12 Jan 2017 17:09:41 +0000 (03:09 +1000)
committerMario <mario@smbclan.net>
Thu, 12 Jan 2017 17:09:41 +0000 (03:09 +1000)
qcsrc/common/monsters/sv_monsters.qc

index fcab35af5334e5e282dc9013e0e12d0ca28d3586..8456e7a64013ac979b90f9362c116589fba60ed5 100644 (file)
@@ -1073,7 +1073,7 @@ void Monster_Damage(entity this, entity inflictor, entity attacker, float damage
 
        this.dmg_time = time;
 
-       if(sound_allowed(MSG_BROADCAST, attacker) && deathtype != DEATH_DROWN.m_id && deathtype != DEATH_FIRE.m_id)
+       if(deathtype != DEATH_DROWN.m_id && deathtype != DEATH_FIRE.m_id && sound_allowed(MSG_BROADCAST, attacker))
                spamsound (this, CH_PAIN, SND(BODYIMPACT1), VOL_BASE, ATTEN_NORM);  // FIXME: PLACEHOLDER
 
        this.velocity += force * this.damageforcescale;