summaryrefslogtreecommitdiff
path: root/src/game/g_cmds.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/game/g_cmds.c')
-rw-r--r--src/game/g_cmds.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/game/g_cmds.c b/src/game/g_cmds.c
index f033cc4..5810f56 100644
--- a/src/game/g_cmds.c
+++ b/src/game/g_cmds.c
@@ -805,7 +805,18 @@ void Cmd_Team_f( gentity_t *ent )
}
if( !Q_stricmpn( s, "spec", 4 ) )
+ {
+ if( g_preventRagequit.integer > 0
+ && ( ( ent->client->pers.teamSelection == PTE_HUMANS && level.numHumanSpawns == 0 )
+ || ( ent->client->pers.teamSelection == PTE_ALIENS && level.numAlienSpawns == 0 ) ) )
+ {
+ AP( va("print \"^3!specme: ^7%s^7 must gather their party before venturing forth from this place. "
+ "^3(ragequit not allowed!)\n\"", ent->client->pers.netname ) );
+ return;
+ }
team = PTE_NONE;
+ }
+
else if( !force && ent->client->pers.teamSelection == PTE_NONE &&
g_maxGameClients.integer && level.numPlayingClients >=
g_maxGameClients.integer )