// These are ALWAYS lethal
// No damage modification here
// Instead, prepare the victim for his death...
- SetResourceAmountExplicit(targ, RESOURCE_ARMOR, 0);
+ SetResourceAmount(targ, RESOURCE_ARMOR, 0);
targ.spawnshieldtime = 0;
- SetResourceAmountExplicit(targ, RESOURCE_HEALTH, 0.9); // this is < 1
+ SetResourceAmount(targ, RESOURCE_HEALTH, 0.9); // this is < 1
targ.flags -= targ.flags & FL_GODMODE;
damage = 100000;
}
}
else if(IS_PLAYER(attacker))
{
- if(deathtype != DEATH_FIRE.m_id)
+ // if enemy gets frozen in this frame and receives other damage don't
+ // play the typehitsound e.g. when hit by multiple bullets of the shotgun
+ if (deathtype != DEATH_FIRE.m_id && (!STAT(FROZEN, victim) || time > victim.freeze_time))
{
attacker.typehitsound += 1;
}