Revert "Shared/Utils: Fixed ApplyPercentModFloatVar."

This reverts commit 2005be0474.

Note to self: do not touch maths past 10 any more.
This commit is contained in:
Warpten
2013-07-11 11:10:05 +02:00
parent f274560c4a
commit 55338ff53b

View File

@@ -114,8 +114,7 @@ inline void ApplyPercentModFloatVar(float& var, float val, bool apply)
{
if (val == -100.0f) // prevent set var to zero
val = -99.99f;
var *= apply ? (100.0f + val) / 100.0f : (100.0f - val) / 100.0f;
var *= (apply ? (100.0f + val) / 100.0f : 100.0f / (100.0f + val));
}
// Percentage calculation