1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-02-21 22:09:41 +00:00

Implement fatigue restoration to match Morrowind.

Fatigue restoration doesn't depend on encuberance or EndFatigueMult.
This commit is contained in:
Michał Ściubidło 2014-07-23 21:25:28 +01:00
parent 91afc2ebe7
commit 432fb751bf

View file

@ -326,11 +326,9 @@ namespace MWMechanics
// restore fatigue
float fFatigueReturnBase = settings.find("fFatigueReturnBase")->getFloat ();
float fFatigueReturnMult = settings.find("fFatigueReturnMult")->getFloat ();
float fEndFatigueMult = settings.find("fEndFatigueMult")->getFloat ();
float x = fFatigueReturnBase + fFatigueReturnMult * (1 - normalizedEncumbrance);
x *= fEndFatigueMult * endurance;
float x = fFatigueReturnBase + fFatigueReturnMult * endurance;
DynamicStat<float> fatigue = stats.getFatigue();
fatigue.setCurrent (fatigue.getCurrent() + duration * x);
stats.setFatigue (fatigue);