Core/Spells Handle auras 328 & 396 (SPELL_AURA_TRIGGER_SPELL_ON_POWER_*)
Port From (https://github.com/TrinityCore/TrinityCore/commit/56e9560661adca81fc1e9a297cb6823cf7a6cb22)
This commit is contained in:
@@ -171,6 +171,11 @@ public static class MathFunctions
|
||||
return (ulong)(value * pct / 100.0f);
|
||||
}
|
||||
|
||||
public static float GetPctOf(float value, float max)
|
||||
{
|
||||
return value / max * 100.0f;
|
||||
}
|
||||
|
||||
public static int RoundToInterval(ref int num, dynamic floor, dynamic ceil)
|
||||
{
|
||||
return num = (int)Math.Min(Math.Max(num, floor), ceil);
|
||||
|
||||
Reference in New Issue
Block a user