From 79c79eb3584f7d860c64294b846f65932ec25a6c Mon Sep 17 00:00:00 2001 From: Finny Merrill Date: Mon, 5 Apr 2004 08:11:46 +0000 Subject: [PATCH] Conc and flash tweaks, as well as fixing the camera bug. --- defs.qh | 22 ++++++++++++---------- scout.qc | 8 +++++++- security.qc | 5 ++--- 3 files changed, 21 insertions(+), 14 deletions(-) diff --git a/defs.qh b/defs.qh index 6c9b6cb..76d9da3 100644 --- a/defs.qh +++ b/defs.qh @@ -825,21 +825,23 @@ float (entity e) EF_GlowColor; #define GL_PIPEBOMB 1 // Defines for Concussion Grenade -#define GR_CONCUSS_AMOUNT 75 -#define GR_CONCUSS_TIME 0.2 -#define GR_CONCUSS_DEC 0.5 -#define GR_CONCUSS_MAX 100 -#define GR_CONCUSS_IDLE 1 -#define GR_CONCUSS_X 0.2 -#define GR_CONCUSS_Y 0.3 -#define GR_CONCUSS_KICK 0.02 -#define GR_CONCUSS_FIXTIME 0.2 -//#define GR_CONCUSS_BUBBLETIME 3 +#define GR_CONCUSS_AMOUNT 75 // Initial conc amount +#define GR_CONCUSS_TIME 0.2 // Time between conc timers +#define GR_CONCUSS_DEC 0.5 // Amount of conc to remove each timer +#define GR_CONCUSS_MAX 100 // Highest amount of conc you can get +#define GR_CONCUSS_IDLE 1 // Idlescale amount +#define GR_CONCUSS_X 0.2 // X mult +#define GR_CONCUSS_Y 0.3 // Y mult +#define GR_CONCUSS_KICK 0.05 // Amount of stumbling you do while moving +#define GR_CONCUSS_FIXTIME 3 // Time between sending setangles +#define GR_CONCUSS_BUBBLETIME 3 #define GR_ANTIGRAV_AMOUNT 100 #define GR_ANTIGRAV_TIME 3 #define GR_ANTIGRAV_DEC 30 +#define NEW_CONCUSS_BOUNCE // New conc bounce algo (same as regular gren) + // Defines for the Gas Grenade #define GR_HALLU_TIME 0.1 #define GR_HALLU_DEC 2.5 diff --git a/scout.qc b/scout.qc index 63d59e7..31d9b0a 100644 --- a/scout.qc +++ b/scout.qc @@ -108,7 +108,7 @@ void() FlashGrenadeExplode = if (ft > 0) te.FlashTime = ft; - stuffcmd (te, "v_cshift 255 255 255 245\n"); // big white flash + stuffcmd (te, "v_cshift 255 255 255 245; wait;wait;wait; bf\n"); // big white flash } } @@ -692,7 +692,12 @@ void(entity inflictor, entity attacker, float bounce, entity ignore) T_RadiusBou if (!IsBuilding(head) && points > 0) { // Bounce!! +#ifdef NEW_CONCUSS_BOUNCE head.velocity += normalize (org - inflictor.origin) * points * 8; +#else + head.velocity = org - inflictor.origin; + head.velocity *= points / 20; +#endif if (head.classname != "player") { @@ -737,6 +742,7 @@ void(entity inflictor, entity attacker, float bounce, entity ignore) T_RadiusBou te.classname = "timer"; te.owner = head; te.health += GR_CONCUSS_AMOUNT; + te.has_tesla = time + 0.1; } } } diff --git a/security.qc b/security.qc index 335b837..32cc0cf 100644 --- a/security.qc +++ b/security.qc @@ -227,9 +227,9 @@ void() Security_Camera_Spawn = self.has_camera = TRUE; newmis = spawn(); newmis.movetype = MOVETYPE_BOUNCE; + newmis.solid = SOLID_BBOX; setsize (newmis, '-16 -16 -3', '16 16 5'); // setsize (newmis, '-8 -8 -8', '8 8 8'); - newmis.solid = SOLID_BBOX; newmis.takedamage = DAMAGE_AIM; newmis.classname = "building_camera"; newmis.netname = "security_camera"; @@ -284,8 +284,7 @@ void() SecurityCameraTossTouch = self.real_owner.option = time + 2; // so ppl cant destroy it for 2 seconds self.movetype = MOVETYPE_NONE; - setsize (self, newmis.mins, newmis.maxs); - self.solid = SOLID_BBOX; + setsize (self, self.mins, self.maxs); self.takedamage = DAMAGE_AIM; sound (self, CHAN_WEAPON, "weapons/guerilla_set.wav", 1, ATTN_NORM); self.think = Security_Camera_Idle;