*Fix the bug that swiftmend heals too much.

--HG--
branch : trunk
This commit is contained in:
megamage
2008-12-08 13:11:45 -06:00
parent 34a13dce42
commit 5321be4c0a

View File

@@ -2351,11 +2351,14 @@ void Spell::EffectHeal( uint32 /*i*/ )
idx++;
}
int32 tickheal = caster->SpellHealingBonus(targetAura->GetSpellProto(), targetAura->GetModifier()->m_amount, DOT, unitTarget);
//int32 tickheal = caster->SpellHealingBonus(targetAura->GetSpellProto(), targetAura->GetModifier()->m_amount, DOT, unitTarget);
int32 tickheal = targetAura->GetSpellProto()->EffectBasePoints[idx] + 1;
int32 tickcount = GetSpellDuration(targetAura->GetSpellProto()) / targetAura->GetSpellProto()->EffectAmplitude[idx];
//TODO: do not remove all auras
unitTarget->RemoveAurasDueToSpell(targetAura->GetId());
addhealth += tickheal * tickcount;
addhealth = caster->SpellHealingBonus(m_spellInfo, addhealth,HEAL, unitTarget);
}
else
addhealth = caster->SpellHealingBonus(m_spellInfo, addhealth,HEAL, unitTarget);