summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Angus <tim@ngus.net>2004-02-01 02:17:16 +0000
committerTim Angus <tim@ngus.net>2004-02-01 02:17:16 +0000
commitb3b15cc492b10515706085ae5199713535c1624b (patch)
tree1cf75081c71aa833f5417b6c9d75f07b8c0fc9dc
parent09a7f2f33840dca9cb7ce7cadec2dd96fad94fa9 (diff)
* Added an extra sanity check to evolution tracing after a "void" report
* Commented out telefrag code.. hopefully won't lead to stuck clients * Raised the human item price ramp whilst slackening the alien value ramp * Aliens now have a hard limit of 9 frags and humans 2000 credits
-rw-r--r--src/game/bg_public.h8
-rw-r--r--src/game/g_client.c2
-rw-r--r--src/game/g_cmds.c9
-rw-r--r--src/game/g_combat.c6
-rw-r--r--src/game/g_main.c8
-rw-r--r--src/game/tremulous.h82
6 files changed, 63 insertions, 52 deletions
diff --git a/src/game/bg_public.h b/src/game/bg_public.h
index b5ecb120..85360d22 100644
--- a/src/game/bg_public.h
+++ b/src/game/bg_public.h
@@ -337,14 +337,14 @@ typedef enum
WP_BLASTER,
WP_MACHINEGUN,
+ WP_PAIN_SAW,
WP_SHOTGUN,
- WP_CHAINGUN,
- WP_FLAMER,
+ WP_LAS_GUN,
WP_MASS_DRIVER,
+ WP_CHAINGUN,
WP_PULSE_RIFLE,
+ WP_FLAMER,
WP_LUCIFER_CANNON,
- WP_LAS_GUN,
- WP_PAIN_SAW,
WP_LOCKBLOB_LAUNCHER,
WP_HIVE,
diff --git a/src/game/g_client.c b/src/game/g_client.c
index e4030b30..da1fb811 100644
--- a/src/game/g_client.c
+++ b/src/game/g_client.c
@@ -1396,7 +1396,7 @@ void ClientSpawn( gentity_t *ent, gentity_t *spawn, vec3_t origin, vec3_t angles
if( !( client->sess.sessionTeam == TEAM_SPECTATOR ) )
{
- G_KillBox( ent );
+ /*G_KillBox( ent );*/ //blame this if a newly spawned client gets stuck in another
trap_LinkEntity( ent );
// force the base weapon up
diff --git a/src/game/g_cmds.c b/src/game/g_cmds.c
index 4144b28b..af2b5f13 100644
--- a/src/game/g_cmds.c
+++ b/src/game/g_cmds.c
@@ -936,7 +936,7 @@ void Cmd_Class_f( gentity_t *ent )
vec3_t up = { 0.0f, 0.0f, 1.0f };
int length = 4096;
int i;
- trace_t tr;
+ trace_t tr, tr2;
vec3_t infestOrigin, infestAngles;
int allowedClasses[ PCL_NUM_CLASSES ];
int numClasses = 0;
@@ -991,7 +991,7 @@ void Cmd_Class_f( gentity_t *ent )
VectorCopy( ent->s.pos.trBase, infestOrigin );
- infestOrigin[ 2 ] += ( fabs( toMins[ 2 ] ) - fabs( fromMins[ 2 ] ) ) + 1;
+ infestOrigin[ 2 ] += ( fabs( toMins[ 2 ] ) - fabs( fromMins[ 2 ] ) ) + 1.0f;
VectorCopy( infestOrigin, temp );
temp[ 2 ] += EVOLVE_TRACE_HEIGHT;
@@ -1004,8 +1004,11 @@ void Cmd_Class_f( gentity_t *ent )
trap_Trace( &tr, temp, toMins, toMaxs, infestOrigin, ent->s.number, MASK_SHOT );
VectorCopy( tr.endpos, infestOrigin );
+ //make REALLY sure
+ trap_Trace( &tr2, ent->s.pos.trBase, NULL, NULL, infestOrigin, ent->s.number, MASK_SHOT );
+
//check there is room to evolve
- if( !tr.startsolid )
+ if( !tr.startsolid && tr2.fraction == 1.0f )
{
//...check we can evolve to that class
if( numLevels >= 0 && BG_FindStagesForClass( ent->client->pers.classSelection, g_alienStage.integer ) )
diff --git a/src/game/g_combat.c b/src/game/g_combat.c
index 847d8988..d5e6f2f7 100644
--- a/src/game/g_combat.c
+++ b/src/game/g_combat.c
@@ -259,6 +259,9 @@ void player_die( gentity_t *self, gentity_t *inflictor, gentity_t *attacker, int
//add credit
player->client->ps.persistant[ PERS_CREDIT ] += (int)( (float)classValue * ( numerator / denominator ) );
+
+ if( player->client->ps.persistant[ PERS_CREDIT ] > HUMAN_MAX_CREDITS )
+ player->client->ps.persistant[ PERS_CREDIT ] = HUMAN_MAX_CREDITS;
}
}
}
@@ -267,6 +270,9 @@ void player_die( gentity_t *self, gentity_t *inflictor, gentity_t *attacker, int
self->client->ps.stats[ STAT_PTEAM ] == PTE_HUMANS )
{
attacker->client->ps.persistant[ PERS_CREDIT ]++;
+
+ if( attacker->client->ps.persistant[ PERS_CREDIT ] > HUMAN_MAX_CREDITS )
+ attacker->client->ps.persistant[ PERS_CREDIT ] = HUMAN_MAX_CREDITS;
}
// Add team bonuses
diff --git a/src/game/g_main.c b/src/game/g_main.c
index 8dbf1983..0ad46bb9 100644
--- a/src/game/g_main.c
+++ b/src/game/g_main.c
@@ -162,13 +162,13 @@ static cvarTable_t gameCvarTable[ ] =
{ &g_humanStage, "g_humanStage", "0", 0, 0, qfalse },
{ &g_humanKills, "g_humanKills", "0", 0, 0, qfalse },
{ &g_humanMaxStage, "g_humanMaxStage", "2", 0, 0, qfalse },
- { &g_humanStage2Threshold, "g_humanStage2Threshold", "15", 0, 0, qfalse },
- { &g_humanStage3Threshold, "g_humanStage3Threshold", "30", 0, 0, qfalse },
+ { &g_humanStage2Threshold, "g_humanStage2Threshold", "20", 0, 0, qfalse },
+ { &g_humanStage3Threshold, "g_humanStage3Threshold", "40", 0, 0, qfalse },
{ &g_alienStage, "g_alienStage", "0", 0, 0, qfalse },
{ &g_alienKills, "g_alienKills", "0", 0, 0, qfalse },
{ &g_alienMaxStage, "g_alienMaxStage", "2", 0, 0, qfalse },
- { &g_alienStage2Threshold, "g_alienStage2Threshold", "15", 0, 0, qfalse },
- { &g_alienStage3Threshold, "g_alienStage3Threshold", "30", 0, 0, qfalse },
+ { &g_alienStage2Threshold, "g_alienStage2Threshold", "20", 0, 0, qfalse },
+ { &g_alienStage3Threshold, "g_alienStage3Threshold", "40", 0, 0, qfalse },
{ &g_debugMapRotation, "g_debugMapRotation", "0", 0, 0, qfalse },
{ &g_currentMapRotation, "g_currentMapRotation", "-1", 0, 0, qfalse }, // -1 = NOT_ROTATING
diff --git a/src/game/tremulous.h b/src/game/tremulous.h
index 7daac11e..a8960a0e 100644
--- a/src/game/tremulous.h
+++ b/src/game/tremulous.h
@@ -38,7 +38,7 @@
#define ABUILDER_BLOB_TIME 5000
#define SOLDIER_BITE_DMG ADM(60)
-#define SOLDIER_BITE_RANGE 64.0f
+#define SOLDIER_BITE_RANGE 80.0f
#define SOLDIER_BITE_REPEAT 500
#define HYDRA_CLAW_DMG ADM(40)
@@ -131,37 +131,37 @@
#define HYDRA_COST 1
#define HYDRA_UPG_SPEED 1.25f
-#define HYDRA_UPG_VALUE AVM(250)
+#define HYDRA_UPG_VALUE AVM(275)
#define HYDRA_UPG_HEALTH AHM(100)
#define HYDRA_UPG_REGEN 2
#define HYDRA_UPG_COST 1
#define CHIMERA_SPEED 1.2f
-#define CHIMERA_VALUE AVM(500)
+#define CHIMERA_VALUE AVM(350)
#define CHIMERA_HEALTH AHM(150)
#define CHIMERA_REGEN 3
#define CHIMERA_COST 1
#define CHIMERA_UPG_SPEED 1.2f
-#define CHIMERA_UPG_VALUE AVM(600)
+#define CHIMERA_UPG_VALUE AVM(450)
#define CHIMERA_UPG_HEALTH AHM(175)
#define CHIMERA_UPG_REGEN 4
#define CHIMERA_UPG_COST 1
#define DRAGOON_SPEED 1.2f
-#define DRAGOON_VALUE AVM(600)
+#define DRAGOON_VALUE AVM(500)
#define DRAGOON_HEALTH AHM(250)
#define DRAGOON_REGEN 5
#define DRAGOON_COST 1
#define DRAGOON_UPG_SPEED 1.2f
-#define DRAGOON_UPG_VALUE AVM(700)
+#define DRAGOON_UPG_VALUE AVM(600)
#define DRAGOON_UPG_HEALTH AHM(300)
#define DRAGOON_UPG_REGEN 6
#define DRAGOON_UPG_COST 1
#define BMOFO_SPEED 1.1f
-#define BMOFO_VALUE AVM(1000)
+#define BMOFO_VALUE AVM(800)
#define BMOFO_HEALTH AHM(350)
#define BMOFO_REGEN 7
#define BMOFO_COST 2
@@ -300,7 +300,7 @@
#define HUMAN_WDMG_MODIFIER 1.0f
#define HDM(d) ((int)((float)d*HUMAN_WDMG_MODIFIER))
-#define BLASTER_REPEAT 1000
+#define BLASTER_REPEAT 600
#define BLASTER_SPREAD 200
#define BLASTER_SPEED 700
#define BLASTER_DMG HDM(10)
@@ -314,49 +314,60 @@
#define RIFLE_SPREAD 200
#define RIFLE_DMG HDM(5)
+#define PAINSAW_PRICE 100
+#define PAINSAW_REPEAT 75
+#define PAINSAW_DAMAGE HDM(5)
+#define PAINSAW_RANGE 48.0f
+
+#define SHOTGUN_PRICE 150
#define SHOTGUN_SHELLS 8
#define SHOTGUN_PELLETS 8 //used to sync server and client side
#define SHOTGUN_SPAWNCLIPS 2
#define SHOTGUN_MAXCLIPS 2
#define SHOTGUN_REPEAT 1200
#define SHOTGUN_RELOAD 2000
-#define SHOTGUN_PRICE 150
#define SHOTGUN_SPREAD 900
#define SHOTGUN_DMG HDM(12)
-#define CHAINGUN_BULLETS 200
-#define CHAINGUN_REPEAT 75
-#define CHAINGUN_PRICE 300
-#define CHAINGUN_SPREAD 1200
-#define CHAINGUN_DMG HDM(6)
-
-#define FLAMER_GAS 80
-#define FLAMER_REPEAT 300
-#define FLAMER_PRICE 350
-#define FLAMER_DMG HDM(30)
-#define FLAMER_RADIUS 50
-#define FLAMER_LIFETIME 1000.0f
-#define FLAMER_SPEED 200.0f
-#define FLAMER_LAG 0.65f //the amount of player velocity that is added to the fireball
+#define LASGUN_PRICE 250
+#define LASGUN_AMMO 80
+#define LASGUN_REPEAT 150
+#define LASGUN_RELOAD 2000
+#define LASGUN_DAMAGE HDM(10)
+#define MDRIVER_PRICE 350
#define MDRIVER_CLIPSIZE 5
#define MDRIVER_SPAWNCLIPS 2
#define MDRIVER_MAXCLIPS 3
-#define MDRIVER_PRICE 250
#define MDRIVER_DMG HDM(50)
#define MDRIVER_REPEAT 1000
#define MDRIVER_RELOAD 2000
+#define CHAINGUN_PRICE 400
+#define CHAINGUN_BULLETS 200
+#define CHAINGUN_REPEAT 75
+#define CHAINGUN_SPREAD 1200
+#define CHAINGUN_DMG HDM(6)
+
+#define PRIFLE_PRICE 400
#define PRIFLE_CLIPS 50
#define PRIFLE_SPAWNCLIPS 3
#define PRIFLE_MAXCLIPS 3
-#define PRIFLE_PRICE 300
#define PRIFLE_REPEAT 100
#define PRIFLE_RELOAD 2000
#define PRIFLE_DMG HDM(13)
#define PRIFLE_SPEED 1500
-#define LCANNON_PRICE 400
+#define FLAMER_PRICE 450
+#define FLAMER_GAS 80
+#define FLAMER_REPEAT 300
+#define FLAMER_DMG HDM(30)
+#define FLAMER_RADIUS 50
+#define FLAMER_LIFETIME 1000.0f
+#define FLAMER_SPEED 200.0f
+#define FLAMER_LAG 0.65f //the amount of player velocity that is added to the fireball
+
+#define LCANNON_PRICE 600
#define LCANNON_AMMO 60
#define LCANNON_REPEAT 500
#define LCANNON_CHARGEREPEAT 1000
@@ -369,23 +380,11 @@
#define LCANNON_CHARGE_TIME 1000
#define LCANNON_TOTAL_CHARGE 255
-
-#define LASGUN_PRICE 200
-#define LASGUN_AMMO 100
-#define LASGUN_REPEAT 150
-#define LASGUN_RELOAD 2000
-#define LASGUN_DAMAGE HDM(15)
-
-#define PAINSAW_PRICE 100
-#define PAINSAW_REPEAT 75
-#define PAINSAW_DAMAGE HDM(5)
-#define PAINSAW_RANGE 48.0f
-
#define HBUILD_PRICE 0
#define HBUILD_REPEAT 1000
#define HBUILD_DELAY 9000
-#define HBUILD2_PRICE 200
+#define HBUILD2_PRICE 75
#define HBUILD2_REPEAT 1000
#define HBUILD2_DELAY 4000
@@ -403,7 +402,7 @@
#define ANTITOXIN_PRICE 20
#define BATTPACK_PRICE 100
-#define BATTPACK_MODIFIER 2.0f //modifier for extra energy storage available
+#define BATTPACK_MODIFIER 1.5f //modifier for extra energy storage available
#define JETPACK_PRICE 120
#define JETPACK_FLOAT_SPEED 128.0f //up movement speed
@@ -528,3 +527,6 @@
#define MIN_FALL_DISTANCE 30.0f //the fall distance at which fall damage kicks in
#define MAX_FALL_DISTANCE 120.0f //the fall distance at which maximum damage is dealt
#define AVG_FALL_DISTANCE ((MIN_FALL_DISTANCE+MAX_FALL_DISTANCE)/2.0f)
+
+#define HUMAN_MAX_CREDITS 2000
+#define ALIEN_MAX_KILLS 9