From 527094c03ee3aa2a1eb4da9e6c6ce0d5f5b2aff6 Mon Sep 17 00:00:00 2001 From: "Tony J. White" Date: Mon, 26 Mar 2007 04:32:20 +0000 Subject: * (bug 3071) fixed new teamvote typos and stopped using ps.stats[ STAT_PTEAM ] for consistency --- src/game/g_cmds.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'src') diff --git a/src/game/g_cmds.c b/src/game/g_cmds.c index 4ffd1144..ea7ed83f 100644 --- a/src/game/g_cmds.c +++ b/src/game/g_cmds.c @@ -1254,15 +1254,15 @@ void Cmd_CallTeamVote_f( gentity_t *ent ) int clientNum = -1; char name[ MAX_NETNAME ]; - if( ent->client->pers.teamSelection == PTE_NONE ) + team = ent->client->pers.teamSelection; + + if( team == PTE_NONE ) { trap_SendServerCommand( ent-g_entities, "print \"Not allowed to call a team vote as a spectator\n\"" ); return; } - team = ent->client->ps.stats[ STAT_PTEAM ]; - if( team == PTE_HUMANS ) cs_offset = 0; else if( team == PTE_ALIENS ) @@ -1346,7 +1346,7 @@ void Cmd_CallTeamVote_f( gentity_t *ent ) if( clientNum == -1 ) { trap_SendServerCommand( ent-g_entities, - "print \"callvote: invalid player\n\"" ); + "print \"callteamvote: invalid player\n\"" ); return; } @@ -1372,14 +1372,14 @@ void Cmd_CallTeamVote_f( gentity_t *ent ) if( clientNum == -1 ) { trap_SendServerCommand( ent-g_entities, - "print \"callvote: invalid player\n\"" ); + "print \"callteamvote: invalid player\n\"" ); return; } if( level.clients[ clientNum ].pers.denyBuild ) { trap_SendServerCommand( ent-g_entities, - "print \"callvote: player already lost building rights\n\"" ); + "print \"callteamvote: player already lost building rights\n\"" ); return; } @@ -1401,14 +1401,14 @@ void Cmd_CallTeamVote_f( gentity_t *ent ) if( clientNum == -1 ) { trap_SendServerCommand( ent-g_entities, - "print \"callvote: invalid player\n\"" ); + "print \"callteamvote: invalid player\n\"" ); return; } if( !level.clients[ clientNum ].pers.denyBuild ) { trap_SendServerCommand( ent-g_entities, - "print \"callvote: player already has building rights\n\"" ); + "print \"callteamvote: player already has building rights\n\"" ); return; } @@ -1431,7 +1431,7 @@ void Cmd_CallTeamVote_f( gentity_t *ent ) trap_SendServerCommand( ent-g_entities, "print \"Invalid vote string\n\"" ); trap_SendServerCommand( ent-g_entities, "print \"Valid team vote commands are: " - "kick, denybuild, allowbuild and surrender\n\"" ); + "kick, denybuild, allowbuild and admitdefeat\n\"" ); return; } ent->client->pers.voteCount++; -- cgit