diff options
author | Tim Angus <tim@ngus.net> | 2006-07-31 21:41:42 +0000 |
---|---|---|
committer | Tim Angus <tim@ngus.net> | 2006-07-31 21:41:42 +0000 |
commit | 965b4ecd1b64328e60a13c9d0643f3c718f128af (patch) | |
tree | 29035e291f1994d97130b83efa9d70ea44cf79f0 /src/game/g_weapon.c | |
parent | 91d17e135e2c4cc9869ab846f72798f018775c5c (diff) |
* Fix to ClientSpawn: spawn is NULL bug #2732 (tjw)
* Fix to lcannon spam bug #2758 (tjw)
* Fix to goon pounce bug #2758 (tjw)
Diffstat (limited to 'src/game/g_weapon.c')
-rw-r--r-- | src/game/g_weapon.c | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/src/game/g_weapon.c b/src/game/g_weapon.c index d57f259f..18c3b8fc 100644 --- a/src/game/g_weapon.c +++ b/src/game/g_weapon.c @@ -579,9 +579,16 @@ void LCChargeFire( gentity_t *ent, qboolean secondary ) gentity_t *m; if( secondary ) - m = fire_luciferCannon( ent, muzzle, forward, LCANNON_SECONDARY_DAMAGE, LCANNON_SECONDARY_RADIUS ); + { + m = fire_luciferCannon( ent, muzzle, forward, LCANNON_SECONDARY_DAMAGE, + LCANNON_SECONDARY_RADIUS ); + ent->client->ps.weaponTime = LCANNON_REPEAT; + } else + { m = fire_luciferCannon( ent, muzzle, forward, ent->client->ps.stats[ STAT_MISC ], LCANNON_RADIUS ); + ent->client->ps.weaponTime = LCANNON_CHARGEREPEAT; + } ent->client->ps.stats[ STAT_MISC ] = 0; } @@ -1260,15 +1267,15 @@ qboolean CheckPounceAttack( gentity_t *ent ) VectorSet( mins, -LEVEL3_POUNCE_WIDTH, -LEVEL3_POUNCE_WIDTH, -LEVEL3_POUNCE_WIDTH ); VectorSet( maxs, LEVEL3_POUNCE_WIDTH, LEVEL3_POUNCE_WIDTH, LEVEL3_POUNCE_WIDTH ); - if( !ent->client->allowedToPounce ) - return qfalse; - if( ent->client->ps.groundEntityNum != ENTITYNUM_NONE ) { ent->client->allowedToPounce = qfalse; - return qfalse; + ent->client->pmext.pouncePayload = 0; } + if( !ent->client->allowedToPounce ) + return qfalse; + if( ent->client->ps.weaponTime ) return qfalse; @@ -1303,7 +1310,10 @@ qboolean CheckPounceAttack( gentity_t *ent ) if( !traceEnt->takedamage ) return qfalse; - damage = (int)( ( (float)ent->client->pouncePayload / (float)LEVEL3_POUNCE_SPEED ) * LEVEL3_POUNCE_DMG ); + damage = (int)( ( (float)ent->client->pmext.pouncePayload + / (float)LEVEL3_POUNCE_SPEED ) * LEVEL3_POUNCE_DMG ); + + ent->client->pmext.pouncePayload = 0; G_Damage( traceEnt, ent, ent, forward, tr.endpos, damage, DAMAGE_NO_KNOCKBACK|DAMAGE_NO_LOCDAMAGE, MOD_LEVEL3_POUNCE ); |