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.c24
1 files changed, 10 insertions, 14 deletions
diff --git a/src/game/g_main.c b/src/game/g_main.c
index a1219909..b753bdc7 100644
--- a/src/game/g_main.c
+++ b/src/game/g_main.c
@@ -220,14 +220,14 @@ static cvarTable_t gameCvarTable[ ] =
{ &g_alienMaxStage, "g_alienMaxStage", DEFAULT_ALIEN_MAX_STAGE, 0, 0, qfalse },
{ &g_alienStage2Threshold, "g_alienStage2Threshold", DEFAULT_ALIEN_STAGE2_THRESH, 0, 0, qfalse },
{ &g_alienStage3Threshold, "g_alienStage3Threshold", DEFAULT_ALIEN_STAGE3_THRESH, 0, 0, qfalse },
-
+
{ &g_unlagged, "g_unlagged", "1", CVAR_SERVERINFO | CVAR_ARCHIVE, 0, qfalse },
{ &g_disabledEquipment, "g_disabledEquipment", "", CVAR_ROM, 0, qfalse },
{ &g_disabledClasses, "g_disabledClasses", "", CVAR_ROM, 0, qfalse },
{ &g_disabledBuildables, "g_disabledBuildables", "", CVAR_ROM, 0, qfalse },
- { &g_chatTeamPrefix, "g_chatTeamPrefix", "0", CVAR_ARCHIVE },
+ { &g_chatTeamPrefix, "g_chatTeamPrefix", "0", CVAR_ARCHIVE, 0, qfalse },
{ &g_markDeconstruct, "g_markDeconstruct", "1", CVAR_SERVERINFO | CVAR_ARCHIVE, 0, qfalse },
@@ -248,13 +248,13 @@ static cvarTable_t gameCvarTable[ ] =
{ &g_adminParseSay, "g_adminParseSay", "1", CVAR_ARCHIVE, 0, qfalse },
{ &g_adminNameProtect, "g_adminNameProtect", "1", CVAR_ARCHIVE, 0, qfalse },
{ &g_adminTempBan, "g_adminTempBan", "120", CVAR_ARCHIVE, 0, qfalse },
-
+
{ &g_dretchPunt, "g_dretchPunt", "0", CVAR_ARCHIVE, 0, qfalse },
{ &g_privateMessages, "g_privateMessages", "1", CVAR_ARCHIVE, 0, qfalse },
-
+
{ &g_tag, "g_tag", "main", CVAR_INIT, 0, qfalse },
-
+
{ &g_rankings, "g_rankings", "0", 0, 0, qfalse}
};
@@ -507,7 +507,7 @@ void G_MapConfigs( const char *mapname )
trap_SendConsoleCommand( EXEC_APPEND,
va( "exec \"%s/default.cfg\"\n", g_mapConfigs.string ) );
-
+
trap_SendConsoleCommand( EXEC_APPEND,
va( "exec \"%s/%s.cfg\"\n", g_mapConfigs.string, mapname ) );
@@ -577,9 +577,7 @@ void G_InitGame( int levelTime, int randomSeed, int restart )
// we're done with g_mapConfigs, so reset this for the next map
trap_Cvar_Set( "g_mapConfigsLoaded", "0" );
- if ( g_admin.string[ 0 ] ) {
- G_admin_readconfig( NULL, 0 );
- }
+ G_admin_readconfig( NULL, 0 );
// initialize all entities for this game
memset( g_entities, 0, MAX_GENTITIES * sizeof( g_entities[ 0 ] ) );
@@ -1302,7 +1300,6 @@ void CalculateRanks( void )
int ff = 0;
level.numConnectedClients = 0;
- level.numNonSpectatorClients = 0;
level.numPlayingClients = 0;
level.numVotingClients = 0; // don't count bots
level.numAlienClients = 0;
@@ -1326,9 +1323,6 @@ void CalculateRanks( void )
if( level.clients[ i ].pers.teamSelection != PTE_NONE )
{
level.numPlayingClients++;
- if( level.clients[ i ].sess.sessionTeam != TEAM_SPECTATOR )
- level.numNonSpectatorClients++;
-
if( level.clients[ i ].pers.teamSelection == PTE_ALIENS )
{
level.numAlienClients++;
@@ -1344,6 +1338,8 @@ void CalculateRanks( void )
}
}
}
+ level.numNonSpectatorClients = level.numLiveAlienClients +
+ level.numLiveHumanClients;
level.numteamVotingClients[ 0 ] = level.numHumanClients;
level.numteamVotingClients[ 1 ] = level.numAlienClients;
P[ i + 1 ] = '\0';
@@ -2345,7 +2341,7 @@ void G_RunFrame( int levelTime )
ClientEndFrame( ent );
}
- // save position information for all active clients
+ // save position information for all active clients
G_UnlaggedStore( );
end = trap_Milliseconds();