Core/Spells: Fixed random huge DoT damage ticks

Closes #726
This commit is contained in:
Shauren
2011-02-25 17:11:02 +01:00
parent 3525cb39b8
commit bc94dcfbe4
+1 -1
View File
@@ -16848,7 +16848,7 @@ uint32 Unit::GetRemainingDotDamage(uint64 caster, uint32 spellId, uint8 effectIn
{
if ((*i)->GetCasterGUID() != caster || (*i)->GetId() != spellId || (*i)->GetEffIndex() != effectIndex)
continue;
amount += ((*i)->GetAmount() * ((*i)->GetTotalTicks() - ((*i)->GetTickNumber()))) / (*i)->GetTotalTicks();
amount += uint32(((*i)->GetAmount() * std::max<int32>((*i)->GetTotalTicks() - int32((*i)->GetTickNumber()), 0)) / (*i)->GetTotalTicks());
break;
}