#include <server/items/items.qh>
#include <server/mutators/_mod.qh>
#include <server/main.qh>
+#include <server/world.qh>
#include "teamplay.qh"
#include "scores.qh"
#include "spawnpoints.qh"
damage = 0;
force = '0 0 0';
}
- else if(SAME_TEAM(attacker, targ))
+ else if(!STAT(FROZEN, targ) && SAME_TEAM(attacker, targ))
{
if(autocvar_teamplay_mode == 1)
damage = 0;
if (!DEATH_ISSPECIAL(deathtype))
{
- damage *= g_weapondamagefactor;
- mirrordamage *= g_weapondamagefactor;
- complainteamdamage *= g_weapondamagefactor;
- force = force * g_weaponforcefactor;
- mirrorforce *= g_weaponforcefactor;
+ damage *= autocvar_g_weapondamagefactor;
+ mirrordamage *= autocvar_g_weapondamagefactor;
+ complainteamdamage *= autocvar_g_weapondamagefactor;
+ force = force * autocvar_g_weaponforcefactor;
+ mirrorforce *= autocvar_g_weaponforcefactor;
}
// should this be changed at all? If so, in what way?
if(IS_PLAYER(victim) || (IS_TURRET(victim) && victim.active == ACTIVE_ACTIVE) || IS_MONSTER(victim) || MUTATOR_CALLHOOK(PlayHitsound, victim, attacker))
{
- if(DIFF_TEAM(victim, attacker) && !STAT(FROZEN, victim))
+ if (DIFF_TEAM(victim, attacker))
{
if(damage > 0)
{
}
}
}
- else if(IS_PLAYER(attacker))
+ else if (IS_PLAYER(attacker) && !STAT(FROZEN, victim)) // same team
{
- // 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))
+ if (deathtype != DEATH_FIRE.m_id)
{
attacker.typehitsound += 1;
}