Merge pull request #2458 from Capostrophic/jump

Don't "jump" with 0 vertical velocity in all cases (bug #5106)
pull/541/head
Andrei Kortunov 5 years ago committed by GitHub
commit b09f0f8c2d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -120,6 +120,7 @@
Bug #5099: Non-swimming enemies will enter water if player is water walking
Bug #5104: Black Dart's enchantment doesn't trigger at low Enchant levels
Bug #5105: NPCs start combat with werewolves from any distance
Bug #5106: Still can jump even when encumbered
Bug #5110: ModRegion with a redundant numerical argument breaks script execution
Bug #5112: Insufficient magicka for current spell not reflected on HUD icon
Bug #5123: Script won't run on respawn

@ -2014,7 +2014,8 @@ void CharacterController::update(float duration, bool animationOnly)
cls.getCreatureStats(mPtr).setFatigue(fatigue);
}
if(sneak || inwater || flying || incapacitated || !solid)
float z = cls.getJump(mPtr);
if(sneak || inwater || flying || incapacitated || !solid || z <= 0)
vec.z() = 0.0f;
bool inJump = true;
@ -2037,7 +2038,6 @@ void CharacterController::update(float duration, bool animationOnly)
else if(vec.z() > 0.0f && mJumpState != JumpState_InAir)
{
// Started a jump.
float z = cls.getJump(mPtr);
if (z > 0)
{
if(vec.x() == 0 && vec.y() == 0)

Loading…
Cancel
Save