vector rotate(vector v, float a);
+#define IS_DEAD(s) (((s).classname == "csqcmodel") ? (s).csqcmodel_isdead : ((s).health <= 0))
+
+
// decolorizes and team colors the player name when needed
string playername(string thename, float teamid);
if (!PHYS_DODGING)
return;
- if (PHYS_DEAD(this))
+ if (IS_DEAD(this))
return;
// when swimming, no dodging allowed..
}
#endif
- if(PHYS_DEAD(this))
+ if(IS_DEAD(this))
{
// handle water here
vector midpoint = ((this.absmin + this.absmax) * 0.5);
#define PHYS_INPUT_BUTTON_BUTTON15(s) boolean(input_buttons & BIT(17))
#define PHYS_INPUT_BUTTON_BUTTON16(s) boolean(input_buttons & BIT(18))
- #define PHYS_DEAD(s) ((s).csqcmodel_isdead)
-
#define GAMEPLAYFIX_GRAVITYUNAFFECTEDBYTICRATE (boolean(moveflags & MOVEFLAG_GRAVITYUNAFFECTEDBYTICRATE))
#define GAMEPLAYFIX_NOGRAVITYONGROUND (boolean(moveflags & MOVEFLAG_NOGRAVITYONGROUND))
#define GAMEPLAYFIX_Q2AIRACCELERATE (boolean(moveflags & MOVEFLAG_Q2AIRACCELERATE))
#define PHYS_INPUT_BUTTON_BUTTON15(s) ((s).button15)
#define PHYS_INPUT_BUTTON_BUTTON16(s) ((s).button16)
- #define PHYS_DEAD(s) ((s).deadflag != DEAD_NO)
-
#define GAMEPLAYFIX_GRAVITYUNAFFECTEDBYTICRATE autocvar_sv_gameplayfix_gravityunaffectedbyticrate
#define GAMEPLAYFIX_NOGRAVITYONGROUND autocvar_sv_gameplayfix_nogravityonground
#define GAMEPLAYFIX_Q2AIRACCELERATE autocvar_sv_gameplayfix_q2airaccelerate
#ifdef SVQC
&& (other.takedamage != DAMAGE_NO)
#elif defined(CSQC)
- && !PHYS_DEAD(other)
+ && !IS_DEAD(other)
#endif
)
{ // KIll Kill Kill!!
#endif
// don't change direction for dead or dying stuff
- if(PHYS_DEAD(other)
+ if(IS_DEAD(other)
#ifdef SVQC
&& (other.takedamage == DAMAGE_NO)
#endif
#endif
//Dont chamge direction for dead or dying stuff
- if(PHYS_DEAD(other) && (other.takedamage == DAMAGE_NO))
+ if(IS_DEAD(other) && (other.takedamage == DAMAGE_NO))
{
if (self.wait >= 0)
{
{SELFPARAM();
if (other.health < 1)
#ifdef SVQC
- if (!((other.iscreature || (other.flags & FL_PROJECTILE)) && !PHYS_DEAD(other)))
+ if (!((other.iscreature || (other.flags & FL_PROJECTILE)) && !IS_DEAD(other)))
#elif defined(CSQC)
- if(!((IS_CLIENT(other) || other.classname == "csqcprojectile") && !PHYS_DEAD(other)))
+ if(!((IS_CLIENT(other) || other.classname == "csqcprojectile") && !IS_DEAD(other)))
#endif
return;
#elif defined(CSQC)
if (!IS_PLAYER(other))
return;
- if(PHYS_DEAD(other))
+ if(IS_DEAD(other))
return;
#endif
float check_tdeath(entity player, vector org, vector telefragmin, vector telefragmax)
{
- if (IS_PLAYER(player) && !PHYS_DEAD(player))
+ if (IS_PLAYER(player) && !IS_DEAD(player))
{
TDEATHLOOP(org)
{
if (!(teamplay && autocvar_g_telefrags_teamplay && head.team == player.team))
#endif
if(IS_PLAYER(head))
- if(!PHYS_DEAD(head))
+ if(!IS_DEAD(head))
return 1;
}
}
{SELFPARAM();
// If whatever thats touching the swamp is not a player
// or if its a dead player, just dont care abt it.
- if(!IS_PLAYER(other) || PHYS_DEAD(other))
+ if(!IS_PLAYER(other) || IS_DEAD(other))
return;
EXACTTRIGGER_TOUCH;
return;
#endif
- if(PHYS_DEAD(other))
+ if(IS_DEAD(other))
return;
if(self.team)
void WarpZone_traceline_antilag (entity source, vector v1, vector v2, float nomonst, entity forent, float lag);
+#define IS_DEAD(s) ((s).deadflag != DEAD_NO)
+
#define ITEM_TOUCH_NEEDKILL() (((trace_dpstartcontents | trace_dphitcontents) & DPCONTENTS_NODROP) || (trace_dphitq3surfaceflags & Q3SURFACEFLAG_SKY))
#define ITEM_DAMAGE_NEEDKILL(dt) (((dt) == DEATH_HURTTRIGGER.m_id) || ((dt) == DEATH_SLIME.m_id) || ((dt) == DEATH_LAVA.m_id) || ((dt) == DEATH_SWAMP.m_id))