From 207d3b1e0c289bdbbff98703a7266d238cadac90 Mon Sep 17 00:00:00 2001 From: "M. Kristall" Date: Sat, 3 Oct 2009 11:50:28 +0000 Subject: * (bug 3658) flashing battlesuit in dying animation * (bug 3685) Second barricade pain animation never gets played * (bug 3690) Suicides aren't cancelled when leaving/switching teams * (bug 3700) weird effects when following a dying player --- src/game/g_cmds.c | 9 +++++---- src/game/g_combat.c | 1 - 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'src') diff --git a/src/game/g_cmds.c b/src/game/g_cmds.c index 5c1d1356..37a63a6e 100644 --- a/src/game/g_cmds.c +++ b/src/game/g_cmds.c @@ -557,6 +557,7 @@ void G_LeaveTeam( gentity_t *self ) G_StopFromFollowing( self ); G_TeamVote( self, qfalse ); + ent->suicideTime = 0; for( i = 0; i < level.num_entities; i++ ) { @@ -2665,10 +2666,6 @@ qboolean G_FollowNewClient( gentity_t *ent, int dir ) if( clientnum == original && !selectAny ) continue; //effectively break; - // can't follow self - if( &level.clients[ clientnum ] == ent->client ) - continue; - // can only follow connected clients if( level.clients[ clientnum ].pers.connected != CON_CONNECTED ) continue; @@ -2688,6 +2685,10 @@ qboolean G_FollowNewClient( gentity_t *ent, int dir ) ent->client->pers.teamSelection ) ) continue; + // can't follow dead client + if( level.clients[ clientnum ].ps.stats[ STAT_HEALTH ] <= 0 ) + continue; + // this is good, we can use it ent->client->sess.spectatorClient = clientnum; ent->client->sess.spectatorState = SPECTATOR_FOLLOW; diff --git a/src/game/g_combat.c b/src/game/g_combat.c index a7ba4c59..3d2bcb21 100644 --- a/src/game/g_combat.c +++ b/src/game/g_combat.c @@ -308,7 +308,6 @@ void player_die( gentity_t *self, gentity_t *inflictor, gentity_t *attacker, int ScoreboardMessage( g_entities + i ); } - self->client->pers.classSelection = PCL_NONE; // reset the classtype VectorCopy( self->s.origin, self->client->pers.lastDeathLocation ); self->takedamage = qfalse; // can still be gibbed -- cgit