Core/Spells: remove PrepareSpellScript and PrepareAuraScript macros and make Hooklist use emplace behaivior (#174)

This commit is contained in:
Warpten authored and GitHub committed 2020-08-28 15:40:26 +02:00
1 parent 677990a1b8
commit 2b2fc5fb8a
252 files changed
+3275 -7394

No files matched your search

+47 -91
View File
@@ -90,8 +90,6 @@ enum WarlockSpellIconId
class spell_warl_pet_scaling_01 : public AuraScript
{
PrepareAuraScript(spell_warl_pet_scaling_01);
void CalculateStaminaAmount(AuraEffect const* /*aurEff*/, int32& amount, bool& canBeRecalculated)
{
canBeRecalculated = true;
@@ -165,16 +163,14 @@ class spell_warl_pet_scaling_01 : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_warl_pet_scaling_01::CalculateStaminaAmount, EFFECT_0, SPELL_AURA_MOD_MAX_HEALTH);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_warl_pet_scaling_01::CalculateAttackPowerAmount, EFFECT_1, SPELL_AURA_MOD_ATTACK_POWER);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_warl_pet_scaling_01::CalculateDamageDoneAmount, EFFECT_2, SPELL_AURA_MOD_DAMAGE_DONE);
DoEffectCalcAmount.Register(&spell_warl_pet_scaling_01::CalculateStaminaAmount, EFFECT_0, SPELL_AURA_MOD_MAX_HEALTH);
DoEffectCalcAmount.Register(&spell_warl_pet_scaling_01::CalculateAttackPowerAmount, EFFECT_1, SPELL_AURA_MOD_ATTACK_POWER);
DoEffectCalcAmount.Register(&spell_warl_pet_scaling_01::CalculateDamageDoneAmount, EFFECT_2, SPELL_AURA_MOD_DAMAGE_DONE);
}
};
class spell_warl_pet_scaling_02 : public AuraScript
{
PrepareAuraScript(spell_warl_pet_scaling_02);
void CalculateIntellectAmount(AuraEffect const* /* aurEff */, int32& amount, bool& canBeRecalculated)
{
canBeRecalculated = true;
@@ -234,16 +230,14 @@ class spell_warl_pet_scaling_02 : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_warl_pet_scaling_02::CalculateIntellectAmount, EFFECT_0, SPELL_AURA_MOD_INCREASE_ENERGY);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_warl_pet_scaling_02::CalculateArmorAmount, EFFECT_1, SPELL_AURA_MOD_RESISTANCE);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_warl_pet_scaling_02::CalculateFireResistanceAmount, EFFECT_2, SPELL_AURA_MOD_RESISTANCE);
DoEffectCalcAmount.Register(&spell_warl_pet_scaling_02::CalculateIntellectAmount, EFFECT_0, SPELL_AURA_MOD_INCREASE_ENERGY);
DoEffectCalcAmount.Register(&spell_warl_pet_scaling_02::CalculateArmorAmount, EFFECT_1, SPELL_AURA_MOD_RESISTANCE);
DoEffectCalcAmount.Register(&spell_warl_pet_scaling_02::CalculateFireResistanceAmount, EFFECT_2, SPELL_AURA_MOD_RESISTANCE);
}
};
class spell_warl_pet_scaling_03 : public AuraScript
{
PrepareAuraScript(spell_warl_pet_scaling_03);
void CalculateResistanceAmount(AuraEffect const* aurEff, int32& amount, bool& canBeRecalculated)
{
// Formular: owner resistance of targeted school * 0.4
@@ -257,14 +251,12 @@ class spell_warl_pet_scaling_03 : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_warl_pet_scaling_03::CalculateResistanceAmount, EFFECT_ALL, SPELL_AURA_MOD_RESISTANCE);
DoEffectCalcAmount.Register(&spell_warl_pet_scaling_03::CalculateResistanceAmount, EFFECT_ALL, SPELL_AURA_MOD_RESISTANCE);
}
};
class spell_warl_pet_scaling_04 : public AuraScript
{
PrepareAuraScript(spell_warl_pet_scaling_04);
void CalculateResistanceAmount(AuraEffect const* aurEff, int32& amount, bool& canBeRecalculated)
{
// Formular: owner resistance of targeted school * 0.4
@@ -292,15 +284,13 @@ class spell_warl_pet_scaling_04 : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_warl_pet_scaling_04::CalculateResistanceAmount, EFFECT_0, SPELL_AURA_MOD_RESISTANCE);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_warl_pet_scaling_04::CalculatePowerRegen, EFFECT_1, SPELL_AURA_MOD_POWER_REGEN);
DoEffectCalcAmount.Register(&spell_warl_pet_scaling_04::CalculateResistanceAmount, EFFECT_0, SPELL_AURA_MOD_RESISTANCE);
DoEffectCalcAmount.Register(&spell_warl_pet_scaling_04::CalculatePowerRegen, EFFECT_1, SPELL_AURA_MOD_POWER_REGEN);
}
};
class spell_warl_pet_scaling_05 : public AuraScript
{
PrepareAuraScript(spell_warl_pet_scaling_05);
void CalculateMeleeHitChanceBonusAmount(AuraEffect const* /* aurEff */, int32& amount, bool& canBeRecalculated)
{
canBeRecalculated = true;
@@ -348,16 +338,14 @@ class spell_warl_pet_scaling_05 : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_warl_pet_scaling_05::CalculateMeleeHitChanceBonusAmount, EFFECT_0, SPELL_AURA_MOD_HIT_CHANCE);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_warl_pet_scaling_05::CalculateSpellHitChanceBonusAmount, EFFECT_1, SPELL_AURA_MOD_SPELL_HIT_CHANCE);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_warl_pet_scaling_05::CalculateExpertiseBonusAmount, EFFECT_2, SPELL_AURA_MOD_EXPERTISE);
DoEffectCalcAmount.Register(&spell_warl_pet_scaling_05::CalculateMeleeHitChanceBonusAmount, EFFECT_0, SPELL_AURA_MOD_HIT_CHANCE);
DoEffectCalcAmount.Register(&spell_warl_pet_scaling_05::CalculateSpellHitChanceBonusAmount, EFFECT_1, SPELL_AURA_MOD_SPELL_HIT_CHANCE);
DoEffectCalcAmount.Register(&spell_warl_pet_scaling_05::CalculateExpertiseBonusAmount, EFFECT_2, SPELL_AURA_MOD_EXPERTISE);
}
};
class spell_warl_pet_scaling_06 : public AuraScript
{
PrepareAuraScript(spell_warl_pet_scaling_06);
void CalculateCritChanceBonus(AuraEffect const* /*aurEff*/, int32& amount, bool& canBeRecalculated)
{
canBeRecalculated = true;
@@ -377,15 +365,13 @@ class spell_warl_pet_scaling_06 : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_warl_pet_scaling_06::CalculateMeleeHasteAmount, EFFECT_0, SPELL_AURA_MOD_CRIT_PCT);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_warl_pet_scaling_06::CalculateMeleeHasteAmount, EFFECT_1, SPELL_AURA_MELEE_SLOW);
DoEffectCalcAmount.Register(&spell_warl_pet_scaling_06::CalculateMeleeHasteAmount, EFFECT_0, SPELL_AURA_MOD_CRIT_PCT);
DoEffectCalcAmount.Register(&spell_warl_pet_scaling_06::CalculateMeleeHasteAmount, EFFECT_1, SPELL_AURA_MELEE_SLOW);
}
};
class spell_warl_pet_passive : public AuraScript
{
PrepareAuraScript(spell_warl_pet_passive);
bool Load() override
{
if (!GetCaster() || !GetCaster()->GetOwner() || GetCaster()->GetOwner()->GetTypeId() != TYPEID_PLAYER)
@@ -435,8 +421,8 @@ class spell_warl_pet_passive : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_warl_pet_passive::CalculateAmountCritSpell, EFFECT_0, SPELL_AURA_MOD_SPELL_CRIT_CHANCE);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_warl_pet_passive::CalculateAmountCritMelee, EFFECT_1, SPELL_AURA_MOD_WEAPON_CRIT_PERCENT);
DoEffectCalcAmount.Register(&spell_warl_pet_passive::CalculateAmountCritSpell, EFFECT_0, SPELL_AURA_MOD_SPELL_CRIT_CHANCE);
DoEffectCalcAmount.Register(&spell_warl_pet_passive::CalculateAmountCritMelee, EFFECT_1, SPELL_AURA_MOD_WEAPON_CRIT_PERCENT);
}
};
@@ -447,8 +433,6 @@ public:
class spell_sha_pet_scaling_04_AuraScript : public AuraScript
{
PrepareAuraScript(spell_sha_pet_scaling_04_AuraScript);
bool Load() override
{
if (!GetCaster() || !GetCaster()->GetOwner() || GetCaster()->GetOwner()->GetTypeId() != TYPEID_PLAYER)
@@ -490,8 +474,8 @@ public:
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_sha_pet_scaling_04_AuraScript::CalculateAmountMeleeHit, EFFECT_0, SPELL_AURA_MOD_HIT_CHANCE);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_sha_pet_scaling_04_AuraScript::CalculateAmountSpellHit, EFFECT_1, SPELL_AURA_MOD_SPELL_HIT_CHANCE);
DoEffectCalcAmount.Register(&spell_sha_pet_scaling_04_AuraScript::CalculateAmountMeleeHit, EFFECT_0, SPELL_AURA_MOD_HIT_CHANCE);
DoEffectCalcAmount.Register(&spell_sha_pet_scaling_04_AuraScript::CalculateAmountSpellHit, EFFECT_1, SPELL_AURA_MOD_SPELL_HIT_CHANCE);
}
};
@@ -503,8 +487,6 @@ public:
class spell_hun_pet_scaling_01 : public AuraScript
{
PrepareAuraScript(spell_hun_pet_scaling_01);
bool Validate(SpellInfo const* /*spellInfo*/) override
{
return ValidateSpellInfo(
@@ -554,16 +536,14 @@ class spell_hun_pet_scaling_01 : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_hun_pet_scaling_01::CalculateHealthAmount, EFFECT_0, SPELL_AURA_MOD_MAX_HEALTH);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_hun_pet_scaling_01::CalculateAttackPowerAmount, EFFECT_1, SPELL_AURA_MOD_ATTACK_POWER);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_hun_pet_scaling_01::CalculateDamageDoneAmount, EFFECT_2, SPELL_AURA_MOD_DAMAGE_DONE);
DoEffectCalcAmount.Register(&spell_hun_pet_scaling_01::CalculateHealthAmount, EFFECT_0, SPELL_AURA_MOD_MAX_HEALTH);
DoEffectCalcAmount.Register(&spell_hun_pet_scaling_01::CalculateAttackPowerAmount, EFFECT_1, SPELL_AURA_MOD_ATTACK_POWER);
DoEffectCalcAmount.Register(&spell_hun_pet_scaling_01::CalculateDamageDoneAmount, EFFECT_2, SPELL_AURA_MOD_DAMAGE_DONE);
}
};
class spell_hun_pet_scaling_02 : public AuraScript
{
PrepareAuraScript(spell_hun_pet_scaling_02);
void CalculateResistanceAmount(AuraEffect const* aurEff, int32& amount, bool& canBeRecalculated)
{
// Formular: owner resistance of targeted school * 0.4
@@ -577,14 +557,12 @@ class spell_hun_pet_scaling_02 : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_hun_pet_scaling_02::CalculateResistanceAmount, EFFECT_ALL, SPELL_AURA_MOD_RESISTANCE);
DoEffectCalcAmount.Register(&spell_hun_pet_scaling_02::CalculateResistanceAmount, EFFECT_ALL, SPELL_AURA_MOD_RESISTANCE);
}
};
class spell_hun_pet_scaling_03 : public AuraScript
{
PrepareAuraScript(spell_hun_pet_scaling_03);
void CalculateResistanceAmount(AuraEffect const* aurEff, int32& amount, bool& canBeRecalculated)
{
// Formular: owner resistance of targeted school * 0.4
@@ -616,16 +594,14 @@ class spell_hun_pet_scaling_03 : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_hun_pet_scaling_03::CalculateResistanceAmount, EFFECT_0, SPELL_AURA_MOD_RESISTANCE);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_hun_pet_scaling_03::CalculateResistanceAmount, EFFECT_1, SPELL_AURA_MOD_RESISTANCE);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_hun_pet_scaling_03::CalculateArmorAmount, EFFECT_2, SPELL_AURA_MOD_RESISTANCE);
DoEffectCalcAmount.Register(&spell_hun_pet_scaling_03::CalculateResistanceAmount, EFFECT_0, SPELL_AURA_MOD_RESISTANCE);
DoEffectCalcAmount.Register(&spell_hun_pet_scaling_03::CalculateResistanceAmount, EFFECT_1, SPELL_AURA_MOD_RESISTANCE);
DoEffectCalcAmount.Register(&spell_hun_pet_scaling_03::CalculateArmorAmount, EFFECT_2, SPELL_AURA_MOD_RESISTANCE);
}
};
class spell_hun_pet_scaling_04 : public AuraScript
{
PrepareAuraScript(spell_hun_pet_scaling_04);
void CalculateMeleeHitChanceBonusAmount(AuraEffect const* /* aurEff */, int32& amount, bool& canBeRecalculated)
{
canBeRecalculated = true;
@@ -673,16 +649,14 @@ class spell_hun_pet_scaling_04 : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_hun_pet_scaling_04::CalculateMeleeHitChanceBonusAmount, EFFECT_0, SPELL_AURA_MOD_HIT_CHANCE);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_hun_pet_scaling_04::CalculateSpellHitChanceBonusAmount, EFFECT_1, SPELL_AURA_MOD_SPELL_HIT_CHANCE);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_hun_pet_scaling_04::CalculateExpertiseBonusAmount, EFFECT_2, SPELL_AURA_MOD_EXPERTISE);
DoEffectCalcAmount.Register(&spell_hun_pet_scaling_04::CalculateMeleeHitChanceBonusAmount, EFFECT_0, SPELL_AURA_MOD_HIT_CHANCE);
DoEffectCalcAmount.Register(&spell_hun_pet_scaling_04::CalculateSpellHitChanceBonusAmount, EFFECT_1, SPELL_AURA_MOD_SPELL_HIT_CHANCE);
DoEffectCalcAmount.Register(&spell_hun_pet_scaling_04::CalculateExpertiseBonusAmount, EFFECT_2, SPELL_AURA_MOD_EXPERTISE);
}
};
class spell_hun_pet_scaling_05 : public AuraScript
{
PrepareAuraScript(spell_hun_pet_scaling_05);
void CalculateCritChanceBonus(AuraEffect const* /*aurEff*/, int32& amount, bool& canBeRecalculated)
{
canBeRecalculated = true;
@@ -702,15 +676,13 @@ class spell_hun_pet_scaling_05 : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_hun_pet_scaling_05::CalculateMeleeHasteAmount, EFFECT_0, SPELL_AURA_MOD_CRIT_PCT);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_hun_pet_scaling_05::CalculateMeleeHasteAmount, EFFECT_1, SPELL_AURA_MELEE_SLOW);
DoEffectCalcAmount.Register(&spell_hun_pet_scaling_05::CalculateMeleeHasteAmount, EFFECT_0, SPELL_AURA_MOD_CRIT_PCT);
DoEffectCalcAmount.Register(&spell_hun_pet_scaling_05::CalculateMeleeHasteAmount, EFFECT_1, SPELL_AURA_MELEE_SLOW);
}
};
class spell_hun_pet_passive_crit : public AuraScript
{
PrepareAuraScript(spell_hun_pet_passive_crit);
bool Load() override
{
if (!GetCaster() || !GetCaster()->GetOwner() || GetCaster()->GetOwner()->GetTypeId() != TYPEID_PLAYER)
@@ -764,15 +736,13 @@ class spell_hun_pet_passive_crit : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_hun_pet_passive_crit::CalculateAmountCritSpell, EFFECT_1, SPELL_AURA_MOD_SPELL_CRIT_CHANCE);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_hun_pet_passive_crit::CalculateAmountCritMelee, EFFECT_0, SPELL_AURA_MOD_WEAPON_CRIT_PERCENT);
DoEffectCalcAmount.Register(&spell_hun_pet_passive_crit::CalculateAmountCritSpell, EFFECT_1, SPELL_AURA_MOD_SPELL_CRIT_CHANCE);
DoEffectCalcAmount.Register(&spell_hun_pet_passive_crit::CalculateAmountCritMelee, EFFECT_0, SPELL_AURA_MOD_WEAPON_CRIT_PERCENT);
}
};
class spell_dk_avoidance_passive : public AuraScript
{
PrepareAuraScript(spell_dk_avoidance_passive);
bool Load() override
{
if (!GetCaster() || !GetCaster()->GetOwner() || GetCaster()->GetOwner()->GetTypeId() != TYPEID_PLAYER)
@@ -799,14 +769,12 @@ class spell_dk_avoidance_passive : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_dk_avoidance_passive::CalculateAvoidanceAmount, EFFECT_0, SPELL_AURA_MOD_CREATURE_AOE_DAMAGE_AVOIDANCE);
DoEffectCalcAmount.Register(&spell_dk_avoidance_passive::CalculateAvoidanceAmount, EFFECT_0, SPELL_AURA_MOD_CREATURE_AOE_DAMAGE_AVOIDANCE);
}
};
class spell_dk_pet_scaling_01 : public AuraScript
{
PrepareAuraScript(spell_dk_pet_scaling_01);
bool Load() override
{
if (!GetCaster() || !GetCaster()->GetOwner() || GetCaster()->GetOwner()->GetTypeId() != TYPEID_PLAYER)
@@ -856,16 +824,14 @@ class spell_dk_pet_scaling_01 : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_dk_pet_scaling_01::CalculateStaminaAmount, EFFECT_0, SPELL_AURA_MOD_STAT);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_dk_pet_scaling_01::CalculateStrengthAmount, EFFECT_1, SPELL_AURA_MOD_STAT);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_dk_pet_scaling_01::CalculateDamageDoneAmount, EFFECT_2, SPELL_AURA_MOD_DAMAGE_DONE);
DoEffectCalcAmount.Register(&spell_dk_pet_scaling_01::CalculateStaminaAmount, EFFECT_0, SPELL_AURA_MOD_STAT);
DoEffectCalcAmount.Register(&spell_dk_pet_scaling_01::CalculateStrengthAmount, EFFECT_1, SPELL_AURA_MOD_STAT);
DoEffectCalcAmount.Register(&spell_dk_pet_scaling_01::CalculateDamageDoneAmount, EFFECT_2, SPELL_AURA_MOD_DAMAGE_DONE);
}
};
class spell_dk_pet_scaling_02 : public AuraScript
{
PrepareAuraScript(spell_dk_pet_scaling_02);
bool Load() override
{
if (!GetCaster() || !GetCaster()->GetOwner() || GetCaster()->GetOwner()->GetTypeId() != TYPEID_PLAYER)
@@ -889,14 +855,12 @@ class spell_dk_pet_scaling_02 : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_dk_pet_scaling_02::CalculateAmountMeleeHaste, EFFECT_1, SPELL_AURA_MELEE_SLOW);
DoEffectCalcAmount.Register(&spell_dk_pet_scaling_02::CalculateAmountMeleeHaste, EFFECT_1, SPELL_AURA_MELEE_SLOW);
}
};
class spell_dk_pet_scaling_03 : public AuraScript
{
PrepareAuraScript(spell_dk_pet_scaling_03);
bool Load() override
{
if (!GetCaster() || !GetCaster()->GetOwner() || GetCaster()->GetOwner()->GetTypeId() != TYPEID_PLAYER)
@@ -938,15 +902,13 @@ class spell_dk_pet_scaling_03 : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_dk_pet_scaling_03::CalculateAmountMeleeHit, EFFECT_0, SPELL_AURA_MOD_HIT_CHANCE);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_dk_pet_scaling_03::CalculateAmountSpellHit, EFFECT_1, SPELL_AURA_MOD_SPELL_HIT_CHANCE);
DoEffectCalcAmount.Register(&spell_dk_pet_scaling_03::CalculateAmountMeleeHit, EFFECT_0, SPELL_AURA_MOD_HIT_CHANCE);
DoEffectCalcAmount.Register(&spell_dk_pet_scaling_03::CalculateAmountSpellHit, EFFECT_1, SPELL_AURA_MOD_SPELL_HIT_CHANCE);
}
};
class spell_dk_pet_scaling_05 : public AuraScript
{
PrepareAuraScript(spell_dk_pet_scaling_05);
bool Load() override
{
if (!GetCaster() || !GetCaster()->GetOwner() || GetCaster()->GetOwner()->GetTypeId() != TYPEID_PLAYER)
@@ -974,15 +936,13 @@ class spell_dk_pet_scaling_05 : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_dk_pet_scaling_05::CalculateAmountCritPct, EFFECT_0, SPELL_AURA_MOD_CRIT_PCT);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_dk_pet_scaling_05::CalculateAmountResistance, EFFECT_2, SPELL_AURA_MOD_TARGET_RESISTANCE);
DoEffectCalcAmount.Register(&spell_dk_pet_scaling_05::CalculateAmountCritPct, EFFECT_0, SPELL_AURA_MOD_CRIT_PCT);
DoEffectCalcAmount.Register(&spell_dk_pet_scaling_05::CalculateAmountResistance, EFFECT_2, SPELL_AURA_MOD_TARGET_RESISTANCE);
}
};
class spell_dk_rune_weapon_scaling_02 : public AuraScript
{
PrepareAuraScript(spell_dk_rune_weapon_scaling_02);
bool Load() override
{
if (!GetCaster() || !GetCaster()->GetOwner() || GetCaster()->GetOwner()->GetTypeId() != TYPEID_PLAYER)
@@ -1021,15 +981,13 @@ class spell_dk_rune_weapon_scaling_02 : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_dk_rune_weapon_scaling_02::CalculateDamageDoneAmount, EFFECT_0, SPELL_AURA_MOD_DAMAGE_DONE);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_dk_rune_weapon_scaling_02::CalculateAmountMeleeHaste, EFFECT_1, SPELL_AURA_MELEE_SLOW);
DoEffectCalcAmount.Register(&spell_dk_rune_weapon_scaling_02::CalculateDamageDoneAmount, EFFECT_0, SPELL_AURA_MOD_DAMAGE_DONE);
DoEffectCalcAmount.Register(&spell_dk_rune_weapon_scaling_02::CalculateAmountMeleeHaste, EFFECT_1, SPELL_AURA_MELEE_SLOW);
}
};
class spell_mage_water_elemental_scaling_01 : public AuraScript
{
PrepareAuraScript(spell_mage_water_elemental_scaling_01);
bool Load() override
{
if (!GetCaster() || !GetCaster()->GetOwner() || GetCaster()->GetOwner()->GetTypeId() != TYPEID_PLAYER)
@@ -1081,16 +1039,14 @@ class spell_mage_water_elemental_scaling_01 : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_mage_water_elemental_scaling_01::CalculateHealthAmount, EFFECT_0, SPELL_AURA_MOD_MAX_HEALTH);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_mage_water_elemental_scaling_01::CalculateAttackPowerAmount, EFFECT_1, SPELL_AURA_MOD_ATTACK_POWER);
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_mage_water_elemental_scaling_01::CalculateDamageDoneAmount, EFFECT_2, SPELL_AURA_MOD_DAMAGE_DONE);
DoEffectCalcAmount.Register(&spell_mage_water_elemental_scaling_01::CalculateHealthAmount, EFFECT_0, SPELL_AURA_MOD_MAX_HEALTH);
DoEffectCalcAmount.Register(&spell_mage_water_elemental_scaling_01::CalculateAttackPowerAmount, EFFECT_1, SPELL_AURA_MOD_ATTACK_POWER);
DoEffectCalcAmount.Register(&spell_mage_water_elemental_scaling_01::CalculateDamageDoneAmount, EFFECT_2, SPELL_AURA_MOD_DAMAGE_DONE);
}
};
class spell_mage_water_elemental_scaling_02 : public AuraScript
{
PrepareAuraScript(spell_mage_water_elemental_scaling_02);
bool Load() override
{
if (!GetCaster() || !GetCaster()->GetOwner() || GetCaster()->GetOwner()->GetTypeId() != TYPEID_PLAYER)
@@ -1116,7 +1072,7 @@ class spell_mage_water_elemental_scaling_02 : public AuraScript
void Register() override
{
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_mage_water_elemental_scaling_02::CalculateManaAmount, EFFECT_0, SPELL_AURA_MOD_INCREASE_ENERGY);
DoEffectCalcAmount.Register(&spell_mage_water_elemental_scaling_02::CalculateManaAmount, EFFECT_0, SPELL_AURA_MOD_INCREASE_ENERGY);
}
};