1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-01-16 19:19:56 +00:00

[Client] Use constant instead magic value

This commit is contained in:
Koncord 2017-01-26 21:47:28 +08:00
parent 34a46e6811
commit ab3c2544b5

View file

@ -165,8 +165,9 @@ void LocalPlayer::updateDynamicStats(bool forceUpdate)
static MWMechanics::DynamicStat<float> oldFatigue(ptrCreatureStats->getFatigue());
static float timer = 0;
const float timeoutSec = 0.5;
if ((timer += MWBase::Environment::get().getFrameDuration()) >= 0.5 || forceUpdate)
if ((timer += MWBase::Environment::get().getFrameDuration()) >= timeoutSec || forceUpdate)
{
if (oldHealth != health || oldMagicka != magicka || oldFatigue != fatigue || forceUpdate)
{