Corrected calculation for SPELL_AURA_PERIODIC_DAMAGE_PERCENT

Port From (https://github.com/TrinityCore/TrinityCore/commit/6cd254d83b51d25551536122ea0217df447b2cf3)
This commit is contained in:
hondacrx
2019-08-31 15:31:09 -04:00
parent 86808ec9a5
commit 674f38e912
+2 -2
View File
@@ -5318,8 +5318,8 @@ namespace Game.Spells
}
}
}
else
damage = (uint)target.CountPctFromMaxHealth((int)damage);
else // ceil obtained value, it may happen that 10 ticks for 10% damage may not kill owner
damage = (uint)Math.Ceiling((float)MathFunctions.CalculatePct(target.GetMaxHealth(), damage));
if (!m_spellInfo.HasAttribute(SpellAttr4.FixedDamage))
{