mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-10 06:42:12 +00:00
- Adjusted some gravity related thresholds for the fix from Feb 28. Also removed
some unnecessary floating point math from this code. SVN r1465 (trunk)
This commit is contained in:
parent
e57ff454f2
commit
b072431d3b
2 changed files with 9 additions and 8 deletions
|
@ -1,4 +1,8 @@
|
|||
March 6, 2009 (Changes by Graf Zahl)
|
||||
March 7, 2009 (Changes by Graf Zahl)
|
||||
- Adjusted some gravity related thresholds for the fix from Feb 28. Also removed
|
||||
some unnecessary floating point math from this code.
|
||||
|
||||
March 6, 2009 (Changes by Graf Zahl)
|
||||
- Added Hirogen2's patch for unlimited ammo CVAR.
|
||||
|
||||
March 4, 2009
|
||||
|
|
|
@ -1984,14 +1984,11 @@ void P_ZMovement (AActor *mo)
|
|||
mo->z = mo->floorz;
|
||||
if (mo->momz < 0)
|
||||
{
|
||||
// [RH] avoid integer roundoff by doing comparisons with floats
|
||||
// I can't think of any good reason why this varied with gravity
|
||||
float minmom = 800.f /*level.gravity * mo->Sector->gravity*/ * -655.36f;
|
||||
float mom = (float)mo->momz;
|
||||
const fixed_t minmom = -9*FRACUNIT; // landing speed from a jump with normal gravity
|
||||
|
||||
// Spawn splashes, etc.
|
||||
P_HitFloor (mo);
|
||||
if (mo->DamageType == NAME_Ice && mom < minmom)
|
||||
if (mo->DamageType == NAME_Ice && mo->momz < minmom)
|
||||
{
|
||||
mo->tics = 1;
|
||||
mo->momx = 0;
|
||||
|
@ -2004,7 +2001,7 @@ void P_ZMovement (AActor *mo)
|
|||
if (mo->player)
|
||||
{
|
||||
mo->player->jumpTics = 7; // delay any jumping for a short while
|
||||
if (mom < minmom && !(mo->flags & MF_NOGRAVITY))
|
||||
if (mo->momz < minmom && !(mo->flags & MF_NOGRAVITY))
|
||||
{
|
||||
// Squat down.
|
||||
// Decrease viewheight for a moment after hitting the ground (hard),
|
||||
|
@ -4402,7 +4399,7 @@ foundone:
|
|||
|
||||
// Don't splash for living things with small vertical velocities.
|
||||
// There are levels where the constant splashing from the monsters gets extremely annoying
|
||||
if ((thing->flags3&MF3_ISMONSTER || thing->player) && thing->momz>=-5*FRACUNIT) return Terrains[terrainnum].IsLiquid;
|
||||
if ((thing->flags3&MF3_ISMONSTER || thing->player) && thing->momz>=-6*FRACUNIT) return Terrains[terrainnum].IsLiquid;
|
||||
|
||||
splash = &Splashes[splashnum];
|
||||
|
||||
|
|
Loading…
Reference in a new issue