mirror of
https://github.com/ReactionQuake3/reaction.git
synced 2024-11-11 07:42:15 +00:00
added a alive function
This commit is contained in:
parent
e17282e6d3
commit
aa7efe3d40
1 changed files with 26 additions and 0 deletions
|
@ -5,6 +5,9 @@
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
//
|
//
|
||||||
// $Log$
|
// $Log$
|
||||||
|
// Revision 1.13 2002/07/09 03:23:14 niceass
|
||||||
|
// added a alive function
|
||||||
|
//
|
||||||
// Revision 1.12 2002/06/16 20:06:14 jbravo
|
// Revision 1.12 2002/06/16 20:06:14 jbravo
|
||||||
// Reindented all the source files with "indent -kr -ut -i8 -l120 -lc120 -sob -bad -bap"
|
// Reindented all the source files with "indent -kr -ut -i8 -l120 -lc120 -sob -bad -bap"
|
||||||
//
|
//
|
||||||
|
@ -788,3 +791,26 @@ int RQ3_isZoomed(gentity_t * ent)
|
||||||
(ent->client->ps.stats[STAT_RQ3] & RQ3_ZOOM_MED) == RQ3_ZOOM_MED);
|
(ent->client->ps.stats[STAT_RQ3] & RQ3_ZOOM_MED) == RQ3_ZOOM_MED);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
G_PlayerAlive by NiceAss
|
||||||
|
|
||||||
|
Created to fix complications when inbetween death and being a spectator in TP
|
||||||
|
*/
|
||||||
|
int G_PlayerAlive(gentity_t *ent)
|
||||||
|
{
|
||||||
|
if (g_gametype.integer < GT_TEAM)
|
||||||
|
{
|
||||||
|
if ( ent->health > 0 )
|
||||||
|
return qtrue;
|
||||||
|
else
|
||||||
|
return qfalse;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if ( ent->health > 0 && ( ent->client->sess.sessionTeam == TEAM_RED || other->client->sess.sessionTeam == TEAM_BLUE ) )
|
||||||
|
return qtrue;
|
||||||
|
else
|
||||||
|
return qfalse;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in a new issue