aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVincent-Michael <Vincent_Michael@gmx.de>2012-09-06 11:14:37 -0400
committerKandera <KanderaDev@gmail.com>2012-09-06 11:14:37 -0400
commit9f09713b3e286ba94948c15d64b76b2aed16f8cd (patch)
treed898e1ed47bd4ea08bc925e13998a062b88639ce
parentfb3a360575970173f37533f5cbc32e017822a559 (diff)
Core/Spells: fix extra damage from crits for talents and equipment effects Closes #6647
-rwxr-xr-xsrc/server/game/Entities/Unit/Unit.cpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp
index 27e2cbf358b..864c9f43dc7 100755
--- a/src/server/game/Entities/Unit/Unit.cpp
+++ b/src/server/game/Entities/Unit/Unit.cpp
@@ -11086,9 +11086,12 @@ uint32 Unit::SpellCriticalDamageBonus(SpellInfo const* spellProto, uint32 damage
crit_bonus -= damage;
- // adds additional damage to crit_bonus (from talents)
- if (Player* modOwner = GetSpellModOwner())
- modOwner->ApplySpellMod(spellProto->Id, SPELLMOD_CRIT_DAMAGE_BONUS, crit_bonus);
+ if (damage > uint32(crit_bonus))
+ {
+ // adds additional damage to critBonus (from talents)
+ if (Player* modOwner = GetSpellModOwner())
+ modOwner->ApplySpellMod(spellProto->Id, SPELLMOD_CRIT_DAMAGE_BONUS, crit_bonus);
+ }
crit_bonus += damage;