summaryrefslogtreecommitdiff
path: root/src/game/g_main.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/game/g_main.c')
-rw-r--r--src/game/g_main.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/game/g_main.c b/src/game/g_main.c
index 72c144b9..4212d771 100644
--- a/src/game/g_main.c
+++ b/src/game/g_main.c
@@ -140,6 +140,7 @@ vmCvar_t g_specChat;
vmCvar_t g_publicAdminMessages;
vmCvar_t g_allowTeamOverlay;
+vmCvar_t g_freeStuff;
vmCvar_t g_censorship;
vmCvar_t g_tag;
@@ -281,6 +282,7 @@ static cvarTable_t gameCvarTable[ ] =
{ &g_publicAdminMessages, "g_publicAdminMessages", "1", CVAR_ARCHIVE, 0, qfalse },
{ &g_allowTeamOverlay, "g_allowTeamOverlay", "1", CVAR_ARCHIVE, 0, qtrue },
+ { &g_freeStuff, "g_freeStuff", "0", CVAR_ARCHIVE, 0, qtrue },
{ &g_censorship, "g_censorship", "", CVAR_ARCHIVE, 0, qfalse },
{ &g_tag, "g_tag", "gpp", CVAR_INIT, 0, qfalse }
@@ -2342,6 +2344,25 @@ void G_RunFrame( int levelTime )
// now we are done spawning
level.spawning = qfalse;
+ // give 9 evos to all aliens, to let clients evolve via the menu
+ if( g_freeStuff.integer )
+ {
+ int i;
+ for( i = 0; i < g_maxclients.integer; ++i )
+ {
+ gclient_t *cl = &g_clients[i];
+ if( cl->pers.connected != CON_CONNECTED )
+ continue;
+
+ if( cl->pers.teamSelection == TEAM_ALIENS )
+ {
+ cl->pers.credit = ALIEN_MAX_CREDITS;
+ if( cl->sess.spectatorState != SPECTATOR_FOLLOW )
+ cl->ps.persistant[ PERS_CREDIT ] = cl->pers.credit;
+ }
+ }
+ }
+
//
// go through all allocated objects
//