mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-02-24 09:39:51 +00:00
Don't apply falling damage twice (bug #4608)
This commit is contained in:
parent
c280a71b33
commit
23834b5ed8
@ -107,6 +107,7 @@
|
||||
Bug #4597: <> operator causes a compile error
|
||||
Bug #4604: Picking up gold from the ground only makes 1 grabbed
|
||||
Bug #4607: Scaling for animated collision shapes is applied twice
|
||||
Bug #4608: Falling damage is applied twice
|
||||
Bug #4615: Flicker effects for light sources are handled incorrectly
|
||||
Bug #4617: First person sneaking offset is not applied while the character is in air
|
||||
Bug #4618: Sneaking is possible while the character is flying
|
||||
|
@ -2012,10 +2012,7 @@ void CharacterController::update(float duration)
|
||||
// inflict fall damages
|
||||
if (!godmode)
|
||||
{
|
||||
DynamicStat<float> health = cls.getCreatureStats(mPtr).getHealth();
|
||||
float realHealthLost = static_cast<float>(healthLost * (1.0f - 0.25f * fatigueTerm));
|
||||
health.setCurrent(health.getCurrent() - realHealthLost);
|
||||
cls.getCreatureStats(mPtr).setHealth(health);
|
||||
cls.onHit(mPtr, realHealthLost, true, MWWorld::Ptr(), MWWorld::Ptr(), osg::Vec3f(), true);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user