Fixed Drain Soul increased damage for targets below 25% HP. Closes issue #394. Closes issue #748. Closes issue #938. Rejoice, new era of server-side spells has begun!
--HG-- branch : trunk
This commit is contained in:
@@ -1411,6 +1411,26 @@ void Aura::HandleAuraSpecificMods(AuraApplication const * aurApp, Unit * caster,
|
||||
}
|
||||
}
|
||||
break;
|
||||
case SPELLFAMILY_WARLOCK:
|
||||
// Drain Soul - If the target is at or below 25% health, Drain Soul causes four times the normal damage
|
||||
if (GetSpellProto()->SpellFamilyFlags[0] & 0x00004000)
|
||||
{
|
||||
if (!target)
|
||||
break;
|
||||
if (apply)
|
||||
{
|
||||
if (target != caster && target->GetHealth() <= target->GetMaxHealth() / 4)
|
||||
caster->CastSpell(caster, 200000, true);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (target != caster)
|
||||
caster->RemoveAurasDueToSpell(GetId());
|
||||
else
|
||||
caster->RemoveAurasDueToSpell(200000);
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user