summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/game/g_main.c4
-rw-r--r--src/game/g_spawn.c27
-rw-r--r--src/game/tremulous.h7
3 files changed, 21 insertions, 17 deletions
diff --git a/src/game/g_main.c b/src/game/g_main.c
index 5fbdd4c5..820108dc 100644
--- a/src/game/g_main.c
+++ b/src/game/g_main.c
@@ -224,12 +224,12 @@ static cvarTable_t gameCvarTable[ ] =
{ &g_humanCredits, "g_humanCredits", "0", 0, 0, qfalse },
{ &g_humanMaxStage, "g_humanMaxStage", DEFAULT_HUMAN_MAX_STAGE, 0, 0, qfalse },
{ &g_humanMaxReachedStage, "g_humanMaxReachedStage", "0", 0, 0, qfalse },
- { &g_humanStageThreshold, "g_humanStageThreshold", DEFAULT_HUMAN_STAGE2_THRESH, 0, 0, qfalse },
+ { &g_humanStageThreshold, "g_humanStageThreshold", DEFAULT_HUMAN_STAGE_THRESH, 0, 0, qfalse },
{ &g_alienStage, "g_alienStage", "0", 0, 0, qfalse },
{ &g_alienCredits, "g_alienCredits", "0", 0, 0, qfalse },
{ &g_alienMaxStage, "g_alienMaxStage", DEFAULT_ALIEN_MAX_STAGE, 0, 0, qfalse },
{ &g_alienMaxReachedStage, "g_alienMaxReachedStage", "0", 0, 0, qfalse },
- { &g_alienStageThreshold, "g_alienStageThreshold", DEFAULT_ALIEN_STAGE2_THRESH, 0, 0, qfalse },
+ { &g_alienStageThreshold, "g_alienStageThreshold", DEFAULT_ALIEN_STAGE_THRESH, 0, 0, qfalse },
{ &g_unlagged, "g_unlagged", "1", CVAR_SERVERINFO | CVAR_ARCHIVE, 0, qfalse },
diff --git a/src/game/g_spawn.c b/src/game/g_spawn.c
index e505a21b..c6fe5e06 100644
--- a/src/game/g_spawn.c
+++ b/src/game/g_spawn.c
@@ -626,23 +626,28 @@ void SP_worldspawn( void )
G_SpawnString( "humanMaxStage", DEFAULT_HUMAN_MAX_STAGE, &s );
trap_Cvar_Set( "g_humanMaxStage", s );
- G_SpawnString( "humanStage2Threshold", DEFAULT_HUMAN_STAGE2_THRESH, &s );
- trap_Cvar_Set( "g_humanStage2Threshold", s );
-
- G_SpawnString( "humanStage3Threshold", DEFAULT_HUMAN_STAGE3_THRESH, &s );
- trap_Cvar_Set( "g_humanStage3Threshold", s );
-
+ //for compatibility with 1.1 maps
+ if( G_SpawnString( "humanStage2Threshold", DEFAULT_HUMAN_STAGE_THRESH, &s ) )
+ trap_Cvar_Set( "g_humanStageThreshold", s );
+ else
+ {
+ //proper way
+ G_SpawnString( "humanStageThreshold", DEFAULT_HUMAN_STAGE_THRESH, &s );
+ trap_Cvar_Set( "g_humanStageThreshold", s );
+ }
G_SpawnString( "alienBuildPoints", DEFAULT_ALIEN_BUILDPOINTS, &s );
trap_Cvar_Set( "g_alienBuildPoints", s );
G_SpawnString( "alienMaxStage", DEFAULT_ALIEN_MAX_STAGE, &s );
trap_Cvar_Set( "g_alienMaxStage", s );
- G_SpawnString( "alienStage2Threshold", DEFAULT_ALIEN_STAGE2_THRESH, &s );
- trap_Cvar_Set( "g_alienStage2Threshold", s );
-
- G_SpawnString( "alienStage3Threshold", DEFAULT_ALIEN_STAGE3_THRESH, &s );
- trap_Cvar_Set( "g_alienStage3Threshold", s );
+ if( G_SpawnString( "alienStage2Threshold", DEFAULT_ALIEN_STAGE_THRESH, &s ) )
+ trap_Cvar_Set( "g_alienStageThreshold", s );
+ else
+ {
+ G_SpawnString( "alienStage2Threshold", DEFAULT_ALIEN_STAGE_THRESH, &s );
+ trap_Cvar_Set( "g_alienStageThreshold", s );
+ }
G_SpawnString( "enableDust", "0", &s );
trap_Cvar_Set( "g_enableDust", s );
diff --git a/src/game/tremulous.h b/src/game/tremulous.h
index 07760f82..a95fb74d 100644
--- a/src/game/tremulous.h
+++ b/src/game/tremulous.h
@@ -655,12 +655,11 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
#define FREEKILL_HUMAN LEVEL0_VALUE
#define DEFAULT_ALIEN_BUILDPOINTS "100"
-#define DEFAULT_ALIEN_STAGE2_THRESH "8000"
-#define DEFAULT_ALIEN_STAGE3_THRESH "16000"
+#define DEFAULT_ALIEN_STAGE_THRESH "8000"
#define DEFAULT_ALIEN_MAX_STAGE "2"
#define DEFAULT_HUMAN_BUILDPOINTS "100"
-#define DEFAULT_HUMAN_STAGE2_THRESH "4000"
-#define DEFAULT_HUMAN_STAGE3_THRESH "8000"
+#define DEFAULT_HUMAN_STAGE_THRESH "4000"
+
#define DEFAULT_HUMAN_MAX_STAGE "2"
#define DAMAGE_FRACTION_FOR_KILL 0.5f //how much damage players (versus structures) need to