summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/game/g_main.c20
-rw-r--r--src/game/g_spawn.c8
2 files changed, 16 insertions, 12 deletions
diff --git a/src/game/g_main.c b/src/game/g_main.c
index 9f77e610..8dbf1983 100644
--- a/src/game/g_main.c
+++ b/src/game/g_main.c
@@ -760,7 +760,7 @@ void calculateBuildPoints( void )
g_alienStage.integer, g_humanStage.integer ) );
}
-#define PLAYER_COUNT_MOD 10.0f
+#define PLAYER_COUNT_MOD 5.0f
/*
============
@@ -769,26 +769,30 @@ CalculateStages
*/
void CalculateStages( void )
{
- float playerCountMod = (float)level.numPlayingClients / PLAYER_COUNT_MOD;
+ float alienPlayerCountMod = (float)level.numAlienClients / PLAYER_COUNT_MOD;
+ float humanPlayerCountMod = (float)level.numAlienClients / PLAYER_COUNT_MOD;
- if( playerCountMod < 0.1f )
- playerCountMod = 0.1f;
+ if( alienPlayerCountMod < 0.1f )
+ alienPlayerCountMod = 0.1f;
+
+ if( humanPlayerCountMod < 0.1f )
+ humanPlayerCountMod = 0.1f;
if( g_alienKills.integer >=
- (int)( (float)g_alienStage2Threshold.integer * playerCountMod ) &&
+ (int)( (float)g_alienStage2Threshold.integer * alienPlayerCountMod ) &&
g_alienStage.integer == S1 && g_alienMaxStage.integer > S1 )
trap_Cvar_Set( "g_alienStage", va( "%d", S2 ) );
if( g_alienKills.integer >=
- (int)( (float)g_alienStage3Threshold.integer * playerCountMod ) &&
+ (int)( (float)g_alienStage3Threshold.integer * alienPlayerCountMod ) &&
g_alienStage.integer == S2 && g_alienMaxStage.integer > S2 )
trap_Cvar_Set( "g_alienStage", va( "%d", S3 ) );
if( g_humanKills.integer >=
- (int)( (float)g_humanStage2Threshold.integer * playerCountMod ) &&
+ (int)( (float)g_humanStage2Threshold.integer * humanPlayerCountMod ) &&
g_humanStage.integer == S1 && g_humanMaxStage.integer > S1 )
trap_Cvar_Set( "g_humanStage", va( "%d", S2 ) );
if( g_humanKills.integer >=
- (int)( (float)g_humanStage3Threshold.integer * playerCountMod ) &&
+ (int)( (float)g_humanStage3Threshold.integer * humanPlayerCountMod ) &&
g_humanStage.integer == S2 && g_humanMaxStage.integer > S2 )
trap_Cvar_Set( "g_humanStage", va( "%d", S3 ) );
}
diff --git a/src/game/g_spawn.c b/src/game/g_spawn.c
index 71ecaed8..1684be88 100644
--- a/src/game/g_spawn.c
+++ b/src/game/g_spawn.c
@@ -605,10 +605,10 @@ void SP_worldspawn( void )
G_SpawnString( "humanMaxStage", "2", &s );
trap_Cvar_Set( "g_humanMaxStage", s );
- G_SpawnString( "humanStage2Threshold", "15", &s );
+ G_SpawnString( "humanStage2Threshold", g_humanStage2Threshold.string, &s );
trap_Cvar_Set( "g_humanStage2Threshold", s );
- G_SpawnString( "humanStage3Threshold", "30", &s );
+ G_SpawnString( "humanStage3Threshold", g_humanStage3Threshold.string, &s );
trap_Cvar_Set( "g_humanStage3Threshold", s );
G_SpawnString( "alienBuildPoints", "1000", &s );
@@ -617,10 +617,10 @@ void SP_worldspawn( void )
G_SpawnString( "alienMaxStage", "2", &s );
trap_Cvar_Set( "g_alienMaxStage", s );
- G_SpawnString( "alienStage2Threshold", "15", &s );
+ G_SpawnString( "alienStage2Threshold", g_alienStage2Threshold.string, &s );
trap_Cvar_Set( "g_alienStage2Threshold", s );
- G_SpawnString( "alienStage3Threshold", "30", &s );
+ G_SpawnString( "alienStage3Threshold", g_alienStage3Threshold.string, &s );
trap_Cvar_Set( "g_alienStage3Threshold", s );
G_SpawnString( "enableDust", "0", &s );