Skip to content

Commit

Permalink
[test patch 51] Fixed backfire damage at dispel 34914 and ranks. Patc…
Browse files Browse the repository at this point in the history
…h provided by Maxxie
  • Loading branch information
insider42 committed Dec 28, 2009
1 parent d9a38b4 commit 636cc0b
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 18 deletions.
13 changes: 13 additions & 0 deletions src/game/SpellAuras.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2549,6 +2549,19 @@ void Aura::HandleAuraDummy(bool apply, bool Real)
return;
}

// Vampiric Touch
if ((GetSpellProto()->SpellFamilyFlags & UI64LIT(0x40000000000)) && m_removeMode==AURA_REMOVE_BY_DISPEL)
{
Unit* caster = GetCaster();
if (!caster)
return;

int32 basepoints = GetSpellProto()->EffectBasePoints[1] * 8;
basepoints = caster->SpellDamageBonus(m_target, GetSpellProto(), basepoints, DOT);
m_target->CastCustomSpell(m_target, 64085, &basepoints, NULL, NULL, false);
return;
}

if (m_removeMode == AURA_REMOVE_BY_DEATH)
{
// Stop caster Arcane Missle chanelling on death
Expand Down
18 changes: 0 additions & 18 deletions src/game/Unit.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4127,24 +4127,6 @@ void Unit::RemoveSingleAuraDueToSpellByDispel(uint32 spellId, uint64 casterGUID,
caster->CastSpell(caster, triggeredSpell, true);
return;
}
// Vampiric touch (first dummy aura)
else if (spellEntry->SpellFamilyName == SPELLFAMILY_PRIEST && spellEntry->SpellFamilyFlags & UI64LIT(0x0000040000000000))
{
if (Aura *dot = GetAura(SPELL_AURA_PERIODIC_DAMAGE, SPELLFAMILY_PRIEST, UI64LIT(0x0000040000000000), 0x00000000, casterGUID))
{
if(Unit* caster = dot->GetCaster())
{
int32 bp0 = dot->GetModifier()->m_amount;
bp0 = 8 * caster->SpellDamageBonus(this, spellEntry, bp0, DOT, 1);

// Remove spell auras from stack
RemoveSingleSpellAurasByCasterSpell(spellId, casterGUID, AURA_REMOVE_BY_DISPEL);

CastCustomSpell(this, 64085, &bp0, NULL, NULL, true, NULL, NULL, casterGUID);
return;
}
}
}

RemoveSingleSpellAurasByCasterSpell(spellId, casterGUID, AURA_REMOVE_BY_DISPEL);
}
Expand Down

0 comments on commit 636cc0b

Please sign in to comment.