DM team none was missing a suicide.

This commit is contained in:
Richard Allen 2003-04-09 20:57:21 +00:00
parent c5fecc7474
commit 4bd753c157

View file

@ -5,6 +5,9 @@
//-----------------------------------------------------------------------------
//
// $Log$
// Revision 1.186 2003/04/09 20:57:21 jbravo
// DM team none was missing a suicide.
//
// Revision 1.185 2003/04/09 02:00:43 jbravo
// Fixed team none in DM and some final cleanups for the 3.0 release
//
@ -1139,6 +1142,13 @@ void SetTeam(gentity_t * ent, char *s)
player_die(ent, ent, ent, 100000, MOD_SUICIDE);
}
// JBravo: DM players switching to spectators should also die.
if (g_gametype.integer == GT_FFA && team == TEAM_SPECTATOR && client->ps.pm_type == PM_NORMAL) {
ent->flags &= ~FL_GODMODE;
ent->client->ps.stats[STAT_HEALTH] = ent->health = 0;
player_die(ent, ent, ent, 100000, MOD_SUICIDE);
}
// JBravo: lets set the correct var here.
if (g_gametype.integer >= GT_TEAM) {
client->sess.savedTeam = team;