mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-01-19 21:23:52 +00:00
Fixed instant negative dynamic stat changes being applied as positive
This commit is contained in:
parent
5f9540318a
commit
a7a3ab0c78
1 changed files with 16 additions and 4 deletions
|
@ -578,15 +578,27 @@ namespace MWMechanics
|
|||
value.restore(magnitude);
|
||||
target.getClass().getCreatureStats(target).setAttribute(attribute, value);
|
||||
}
|
||||
else if (effectId == ESM::MagicEffect::DamageHealth || effectId == ESM::MagicEffect::RestoreHealth)
|
||||
else if (effectId == ESM::MagicEffect::DamageHealth)
|
||||
{
|
||||
applyDynamicStatsEffect(0, target, magnitude);
|
||||
applyDynamicStatsEffect(0, target, magnitude * -1);
|
||||
}
|
||||
else if (effectId == ESM::MagicEffect::DamageFatigue || effectId == ESM::MagicEffect::RestoreFatigue)
|
||||
else if (effectId == ESM::MagicEffect::RestoreHealth)
|
||||
{
|
||||
applyDynamicStatsEffect(2, target, magnitude);
|
||||
}
|
||||
else if (effectId == ESM::MagicEffect::DamageMagicka || effectId == ESM::MagicEffect::RestoreMagicka)
|
||||
else if (effectId == ESM::MagicEffect::DamageFatigue)
|
||||
{
|
||||
applyDynamicStatsEffect(2, target, magnitude * -1);
|
||||
}
|
||||
else if (effectId == ESM::MagicEffect::RestoreFatigue)
|
||||
{
|
||||
applyDynamicStatsEffect(2, target, magnitude);
|
||||
}
|
||||
else if (effectId == ESM::MagicEffect::DamageMagicka)
|
||||
{
|
||||
applyDynamicStatsEffect(1, target, magnitude * -1);
|
||||
}
|
||||
else if (effectId == ESM::MagicEffect::RestoreMagicka)
|
||||
{
|
||||
applyDynamicStatsEffect(1, target, magnitude);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue