diff options
-rw-r--r-- | src/game/Unit.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index bc9923a5226..d310880f3b2 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -1903,6 +1903,7 @@ void Unit::CalcAbsorbResist(Unit *pVictim,SpellSchoolMask schoolMask, DamageEffe // Reflect damage spells (not cast any damage spell in aura lookup) uint32 reflectSpell = 0; int32 reflectDamage = 0; + AuraEffect* reflectTriggeredBy = NULL; // expected as not expired at reflect as in current cases uint32 healSpell = 0; int32 healAmount = 0; Unit * healCaster = NULL; @@ -1968,6 +1969,7 @@ void Unit::CalcAbsorbResist(Unit *pVictim,SpellSchoolMask schoolMask, DamageEffe else reflectDamage = currentAbsorb / 2; reflectSpell = 33619; + reflectTriggeredBy = *i; break; } if (spellProto->Id == 39228 || // Argussian Compass @@ -2037,13 +2039,13 @@ void Unit::CalcAbsorbResist(Unit *pVictim,SpellSchoolMask schoolMask, DamageEffe { case 5065: // Rank 1 case 5064: // Rank 2 - case 5063: // Rank 3 { if(RemainingDamage >= currentAbsorb) reflectDamage = (*k)->GetAmount() * currentAbsorb/100; else reflectDamage = (*k)->GetAmount() * RemainingDamage/100; reflectSpell = 33619; + reflectTriggeredBy = *i; } break; } } @@ -2146,7 +2148,7 @@ void Unit::CalcAbsorbResist(Unit *pVictim,SpellSchoolMask schoolMask, DamageEffe // Cast back reflect damage spell if (reflectSpell) - pVictim->CastCustomSpell(this, reflectSpell, &reflectDamage, NULL, NULL, true); + pVictim->CastCustomSpell(this, reflectSpell, &reflectDamage, NULL, NULL, true, NULL, reflectTriggeredBy); // absorb by mana cost AuraEffectList const& vManaShield = pVictim->GetAurasByType(SPELL_AURA_MANA_SHIELD); |