*Cleanups and fixes in Unrelenting Assault.
--HG-- branch : trunk
This commit is contained in:
@@ -2499,6 +2499,29 @@ void AuraEffect::HandleAuraDummy(bool apply, bool Real, bool changeAmount)
|
|||||||
// AT APPLY
|
// AT APPLY
|
||||||
if(apply)
|
if(apply)
|
||||||
{
|
{
|
||||||
|
// Overpower
|
||||||
|
if (caster && m_spellProto->SpellFamilyName == SPELLFAMILY_WARRIOR &&
|
||||||
|
m_spellProto->SpellFamilyFlags[0] & 0x4)
|
||||||
|
{
|
||||||
|
// Must be casting target
|
||||||
|
if (!m_target->IsNonMeleeSpellCasted(false))
|
||||||
|
return;
|
||||||
|
if (AuraEffect * aurEff = caster->GetAuraEffect(SPELL_AURA_ADD_FLAT_MODIFIER, SPELLFAMILY_WARRIOR, 2775, 0))
|
||||||
|
{
|
||||||
|
switch (aurEff->GetId())
|
||||||
|
{
|
||||||
|
// Unrelenting Assault, rank 1
|
||||||
|
case 46859:
|
||||||
|
caster->CastSpell(m_target,64849,true,NULL,aurEff);
|
||||||
|
break;
|
||||||
|
// Unrelenting Assault, rank 2
|
||||||
|
case 46860:
|
||||||
|
caster->CastSpell(m_target,64850,true,NULL,aurEff);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
switch(GetId())
|
switch(GetId())
|
||||||
{
|
{
|
||||||
// Haunting Spirits - perdiodic trigger demon
|
// Haunting Spirits - perdiodic trigger demon
|
||||||
|
|||||||
@@ -1321,35 +1321,6 @@ void Spell::EffectDummy(uint32 i)
|
|||||||
m_damage+= uint32(damage * m_caster->GetTotalAttackPowerValue(BASE_ATTACK) / 100);
|
m_damage+= uint32(damage * m_caster->GetTotalAttackPowerValue(BASE_ATTACK) / 100);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
// Overpower
|
|
||||||
if(m_spellInfo->SpellFamilyFlags[0] & 0x4)
|
|
||||||
{
|
|
||||||
// Must be casting target
|
|
||||||
if (!unitTarget->IsNonMeleeSpellCasted(false))
|
|
||||||
return;
|
|
||||||
// Find Unrelenting Assault
|
|
||||||
Unit::AuraEffectList const& modifierAuras = m_caster->GetAurasByType(SPELL_AURA_ADD_FLAT_MODIFIER);
|
|
||||||
for(Unit::AuraEffectList::const_iterator itr = modifierAuras.begin(); itr != modifierAuras.end(); ++itr)
|
|
||||||
{
|
|
||||||
if((*itr)->GetSpellProto()->SpellFamilyName==SPELLFAMILY_WARRIOR && (*itr)->GetSpellProto()->SpellIconID == 2775)
|
|
||||||
{
|
|
||||||
switch ((*itr)->GetSpellProto()->Id)
|
|
||||||
{
|
|
||||||
// Unrelenting Assault, rank 1
|
|
||||||
case 46859:
|
|
||||||
m_caster->CastSpell(unitTarget,64849,true,0,(*itr));
|
|
||||||
break;
|
|
||||||
// Unrelenting Assault, rank 2
|
|
||||||
case 46860:
|
|
||||||
m_caster->CastSpell(unitTarget,64850,true,0,(*itr));
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
switch(m_spellInfo->Id)
|
switch(m_spellInfo->Id)
|
||||||
{
|
{
|
||||||
// Warrior's Wrath
|
// Warrior's Wrath
|
||||||
|
|||||||
+2
-2
@@ -9335,7 +9335,7 @@ uint32 Unit::SpellDamageBonus(Unit *pVictim, SpellEntry const *spellProto, uint3
|
|||||||
{
|
{
|
||||||
coeff = bonus->direct_damage;
|
coeff = bonus->direct_damage;
|
||||||
if (bonus->ap_bonus > 0)
|
if (bonus->ap_bonus > 0)
|
||||||
DoneTotal+=bonus->ap_dot_bonus * stack * ApCoeffMod * GetTotalAttackPowerValue(
|
DoneTotal+=bonus->ap_bonus * stack * ApCoeffMod * GetTotalAttackPowerValue(
|
||||||
(IsRangedWeaponSpell(spellProto) && spellProto->DmgClass !=SPELL_DAMAGE_CLASS_MELEE)? RANGED_ATTACK : BASE_ATTACK);
|
(IsRangedWeaponSpell(spellProto) && spellProto->DmgClass !=SPELL_DAMAGE_CLASS_MELEE)? RANGED_ATTACK : BASE_ATTACK);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -9810,7 +9810,7 @@ uint32 Unit::SpellHealingBonus(Unit *pVictim, SpellEntry const *spellProto, uint
|
|||||||
{
|
{
|
||||||
coeff = bonus->direct_damage;
|
coeff = bonus->direct_damage;
|
||||||
if (bonus->ap_bonus > 0)
|
if (bonus->ap_bonus > 0)
|
||||||
DoneTotal+=bonus->ap_dot_bonus * stack * GetTotalAttackPowerValue(
|
DoneTotal+=bonus->ap_bonus * stack * GetTotalAttackPowerValue(
|
||||||
(IsRangedWeaponSpell(spellProto) && spellProto->DmgClass !=SPELL_DAMAGE_CLASS_MELEE)? RANGED_ATTACK : BASE_ATTACK);
|
(IsRangedWeaponSpell(spellProto) && spellProto->DmgClass !=SPELL_DAMAGE_CLASS_MELEE)? RANGED_ATTACK : BASE_ATTACK);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user