diff options
author | Michael Levin <risujin@fastmail.fm> | 2009-10-03 11:19:17 +0000 |
---|---|---|
committer | Tim Angus <tim@ngus.net> | 2013-01-03 00:14:52 +0000 |
commit | 9fed6829767d39dbe05f9fa54dfcf18ae792e991 (patch) | |
tree | 4847d5803721eec733ad20943457838d281a5f88 /src/game | |
parent | 5e46c5258c1999af57f2589a6cead5682af6ca5d (diff) |
* Removed forced crouching for Tyrant crush, Tyrants should no longer bounce off of players
* Added a new cvar, cg_hudFilesEnable, set to "1" to enable your custom HUD -- this is a temporary workaround to custom HUD incompatibility!
Diffstat (limited to 'src/game')
-rw-r--r-- | src/game/bg_pmove.c | 4 | ||||
-rw-r--r-- | src/game/bg_public.h | 1 | ||||
-rw-r--r-- | src/game/g_active.c | 7 | ||||
-rw-r--r-- | src/game/g_local.h | 4 | ||||
-rw-r--r-- | src/game/g_weapon.c | 17 |
5 files changed, 4 insertions, 29 deletions
diff --git a/src/game/bg_pmove.c b/src/game/bg_pmove.c index 1547ec1d..76ad71f3 100644 --- a/src/game/bg_pmove.c +++ b/src/game/bg_pmove.c @@ -3620,10 +3620,6 @@ void Pmove( pmove_t *pmove ) msec = 66; } - // force crouch - if( pmove->ps->pm_flags & PMF_FORCE_CROUCH ) - pmove->cmd.upmove = -127; - pmove->cmd.serverTime = pmove->ps->commandTime + msec; PmoveSingle( pmove ); diff --git a/src/game/bg_public.h b/src/game/bg_public.h index 0bceb6c6..858b0740 100644 --- a/src/game/bg_public.h +++ b/src/game/bg_public.h @@ -135,7 +135,6 @@ typedef enum #define PMF_BACKWARDS_RUN 16 // coast down to backwards run #define PMF_TIME_LAND 32 // pm_time is time before rejump #define PMF_TIME_KNOCKBACK 64 // pm_time is an air-accelerate only time -#define PMF_FORCE_CROUCH 128 // force the player to crouch #define PMF_TIME_WATERJUMP 256 // pm_time is waterjump #define PMF_RESPAWNED 512 // clear after attack and jump buttons come up #define PMF_USE_ITEM_HELD 1024 diff --git a/src/game/g_active.c b/src/game/g_active.c index 4d35b6a0..94a8e8c9 100644 --- a/src/game/g_active.c +++ b/src/game/g_active.c @@ -1606,13 +1606,6 @@ void ClientThink_real( gentity_t *ent ) if( !ent->client->noclip ) G_TouchTriggers( ent ); - // Tyrant crush - pm.pmext->fallVelocity = 0; - if( ent->client->forceCrouchTime + 500 > level.time ) - client->ps.pm_flags |= PMF_FORCE_CROUCH; - else - client->ps.pm_flags &= ~PMF_FORCE_CROUCH; - Pmove( &pm ); G_UnlaggedDetectCollisions( ent ); diff --git a/src/game/g_local.h b/src/game/g_local.h index 31654231..932a79c1 100644 --- a/src/game/g_local.h +++ b/src/game/g_local.h @@ -470,9 +470,7 @@ struct gclient_s int lcannonStartTime; - // Tyrant crush - int forceCrouchTime; - int lastCrushTime; + int lastCrushTime; // Tyrant crush }; diff --git a/src/game/g_weapon.c b/src/game/g_weapon.c index 43d221c2..2f3b6fd1 100644 --- a/src/game/g_weapon.c +++ b/src/game/g_weapon.c @@ -1411,18 +1411,6 @@ void G_CrushAttack( gentity_t *ent, gentity_t *victim, float sec ) victim->client->ps.groundEntityNum == ENTITYNUM_NONE ) ) return; - // Force target to crouch first if they can - if( victim->client && - !BG_InventoryContainsUpgrade( UP_BATTLESUIT, victim->client->ps.stats ) && - victim->client->ps.pm_type != PM_JETPACK && - victim->client->pers.cmd.upmove >= 0 && - !( victim->client->ps.pm_flags & - ( PMF_CROUCH_HELD | PMF_FORCE_CROUCH ) ) ) - { - victim->client->forceCrouchTime = level.time; - return; - } - // Deal velocity based damage to target jump = BG_FindJumpMagnitudeForClass( ent->client->ps.stats[ STAT_PCLASS ] ); damage = ( ent->client->pmext.fallVelocity + jump ) * @@ -1430,14 +1418,15 @@ void G_CrushAttack( gentity_t *ent, gentity_t *victim, float sec ) if( damage < 0 ) damage = 0; - + + // Players also get damaged periodically if( victim->client && ent->client->lastCrushTime + LEVEL4_CRUSH_REPEAT < level.time ) { ent->client->lastCrushTime = level.time; damage += LEVEL4_CRUSH_DAMAGE; } - + if( damage < 1 ) return; |