Conc and flash tweaks, as well as fixing the camera bug.

This commit is contained in:
Finny Merrill 2004-04-05 08:11:46 +00:00
parent c4c66161c5
commit 79c79eb358
3 changed files with 21 additions and 14 deletions

22
defs.qh
View file

@ -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

View file

@ -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;
}
}
}

View file

@ -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;