Merge pull request #6522 from Vincent-Michael/TakenCalculation

Core/Spell: Fix SpellDamageBonusTaken calculation for negative value
This commit is contained in:
kandera
2012-05-16 07:55:22 -07:00
+1 -1
View File
@@ -10875,7 +10875,7 @@ uint32 Unit::SpellDamageBonusTaken(Unit* caster, SpellInfo const* spellProto, ui
TakenTotal+= int32(TakenAdvertisedBenefit * coeff * factorMod);
}
float tmpDamage = (pdamage + TakenTotal) * TakenTotalMod;
float tmpDamage = (int32(pdamage) + TakenTotal) * TakenTotalMod;
return uint32(std::max(tmpDamage, 0.0f));
}