Go to the documentation of this file.
45 if (trace.
ent == targ)
97 targ->
enemy = attacker;
104 level.killed_monsters++;
108 if (strcmp(attacker->
classname,
"monster_medic") == 0)
109 targ->
owner = attacker;
115 targ->
die (targ, inflictor, attacker, damage, point);
125 targ->
die (targ, inflictor, attacker, damage, point);
175 int power_armor_type;
234 damage = (2 * damage) / 3;
237 save = power * damagePerCell;
246 power_used = save / damagePerCell;
300 if (attacker == targ || attacker == targ->
enemy)
329 targ->
enemy = attacker;
339 (strcmp(attacker->
classname,
"monster_tank") != 0) &&
340 (strcmp(attacker->
classname,
"monster_supertank") != 0) &&
341 (strcmp(attacker->
classname,
"monster_makron") != 0) &&
342 (strcmp(attacker->
classname,
"monster_jorg") != 0) )
346 targ->
enemy = attacker;
351 else if (attacker->
enemy == targ)
355 targ->
enemy = attacker;
360 else if (attacker->
enemy && attacker->
enemy != targ)
441 if (targ->
client && attacker == targ)
442 VectorScale (dir, 1600.0 * (
float)knockback / mass, kvel);
444 VectorScale (dir, 500.0 * (
float)knockback / mass, kvel);
476 asave =
CheckArmor (targ, point, normal, take, te_sparks, dflags);
501 Killed (targ, inflictor, attacker, take, point);
511 targ->
pain (targ, attacker, knockback, take);
520 targ->
pain (targ, attacker, knockback, take);
525 targ->
pain (targ, attacker, knockback, take);
gitem_t * FindItem(char *pickup_name)
trace_t(* trace)(vec3_t start, vec3_t mins, vec3_t maxs, vec3_t end, edict_t *passent, int contentmask)
#define VectorSubtract(a, b, c)
void(* WritePosition)(vec3_t pos)
void(* multicast)(vec3_t origin, multicast_t to)
int PowerArmorType(edict_t *ent)
void monster_death_use(edict_t *self)
void VectorScale(vec3_t in, vec_t scale, vec3_t out)
struct gclient_s * client
void(* sound)(edict_t *ent, int channel, int soundindex, float volume, float attenuation, float timeofs)
int ArmorIndex(edict_t *ent)
void T_Damage(edict_t *targ, edict_t *inflictor, edict_t *attacker, vec3_t dir, vec3_t point, vec3_t normal, int damage, int knockback, int dflags, int mod)
#define DAMAGE_NO_KNOCKBACK
void AngleVectors(vec3_t angles, vec3_t forward, vec3_t right, vec3_t up)
#define POWER_ARMOR_SCREEN
#define DAMAGE_NO_PROTECTION
edict_t * findradius(edict_t *from, vec3_t org, float rad)
int(* soundindex)(char *name)
vec_t VectorLength(vec3_t v)
qboolean OnSameTeam(edict_t *ent1, edict_t *ent2)
qboolean CheckTeamDamage(edict_t *targ, edict_t *attacker)
vec_t VectorNormalize(vec3_t v)
void FoundTarget(edict_t *self)
static int CheckArmor(edict_t *ent, vec3_t point, vec3_t normal, int damage, int te_sparks, int dflags)
qboolean CanDamage(edict_t *targ, edict_t *inflictor)
void(* pain)(edict_t *self, edict_t *other, float kick, int damage)
#define VectorAdd(a, b, c)
monsterinfo_t monsterinfo
qboolean visible(edict_t *self, edict_t *other)
void M_ReactToDamage(edict_t *targ, edict_t *attacker)
void(* WriteDir)(vec3_t pos)
void Killed(edict_t *targ, edict_t *inflictor, edict_t *attacker, int damage, vec3_t point)
void SpawnDamage(int type, vec3_t origin, vec3_t normal, int damage)
float invincible_framenum
void VectorMA(vec3_t veca, float scale, vec3_t vecb, vec3_t vecc)
gitem_t * GetItemByIndex(int index)
void(* touch)(edict_t *self, edict_t *other, cplane_t *plane, csurface_t *surf)
static int CheckPowerArmor(edict_t *ent, vec3_t point, vec3_t normal, int damage, int dflags)
GLdouble GLdouble GLint GLint const GLdouble * points
void(* die)(edict_t *self, edict_t *inflictor, edict_t *attacker, int damage, vec3_t point)
#define MOD_FRIENDLY_FIRE
#define DF_NO_FRIENDLY_FIRE
void T_RadiusDamage(edict_t *inflictor, edict_t *attacker, float damage, edict_t *ignore, float radius, int mod)