66 float CritSpell = 0.0f;
68 CritSpell += owner->GetSpellCritFromIntellect();
76 amount +=
int32(CritSpell);
85 float CritMelee = 0.0f;
87 CritMelee += owner->GetMeleeCritFromAgility();
95 amount +=
int32(CritMelee);
104 float HitMelee = 0.0f;
110 amount +=
int32(HitMelee);
119 float HitSpell = 0.0f;
125 amount +=
int32(HitSpell);
134 float Expertise = 0.0f;
140 amount +=
int32(Expertise);
194 amount += ownerBonus;
206 switch (pet->GetEntry())
226 pet->ToPet()->SetCreateHealth(baseHealth + healthMod);
236 pet->ToPet()->SetCreateHealth(pInfo->
health);
249 int32 maximum = (fire > shadow) ? fire : shadow;
252 float bonusAP = maximum * 0.57f;
262 amount +=
CalculatePct(amount + base_attPower, ect->GetAmount());
277 int32 maximum = (fire > shadow) ? fire : shadow;
278 float bonusDamage = 0.0f;
281 bonusDamage = maximum * 0.15f;
283 amount += bonusDamage;
329 float ownerBonus = 0.0f;
333 amount += ownerBonus;
346 switch (pet->GetEntry())
362 pet->ToPet()->SetCreateMana(baseMana + manaMod);
372 pet->ToPet()->SetCreateMana(pInfo->
mana);
382 float ownerBonus = 0.0f;
384 amount += ownerBonus;
394 float ownerBonus = 0.0f;
396 amount += ownerBonus;
441 float ownerBonus = 0.0f;
443 amount += ownerBonus;
453 float ownerBonus = 0.0f;
455 amount += ownerBonus;
465 float ownerBonus = 0.0f;
467 amount += ownerBonus;
507 float ownerBonus = 0.0f;
509 amount += ownerBonus;
546 float HitMelee = 0.0f;
552 amount +=
int32(HitMelee);
561 float HitSpell = 0.0f;
567 amount +=
int32(HitSpell);
576 float Expertise = 0.0f;
582 amount +=
int32(Expertise);
621 float CritSpell = 0.0f;
623 CritSpell += owner->GetSpellCritFromIntellect();
631 if (
AuraApplication* improvedDemonicTacticsApp = owner->GetAuraApplicationOfRankedSpell(54347))
632 if (
Aura* improvedDemonicTactics = improvedDemonicTacticsApp->GetBase())
633 if (
AuraEffect* improvedDemonicTacticsEffect = improvedDemonicTactics->GetEffect(
EFFECT_0))
634 amount +=
CalculatePct(CritSpell, improvedDemonicTacticsEffect->GetAmount());
643 float CritMelee = 0.0f;
645 CritMelee += owner->GetMeleeCritFromAgility();
653 if (
AuraApplication* improvedDemonicTacticsApp = owner->GetAuraApplicationOfRankedSpell(54347))
654 if (
Aura* improvedDemonicTactics = improvedDemonicTacticsApp->GetBase())
655 if (
AuraEffect* improvedDemonicTacticsEffect = improvedDemonicTactics->GetEffect(
EFFECT_0))
656 amount +=
CalculatePct(CritMelee, improvedDemonicTacticsEffect->GetAmount());
745 float HitMelee = 0.0f;
751 amount +=
int32(HitMelee);
760 float HitSpell = 0.0f;
766 amount +=
int32(HitSpell);
799 float ownerBonus = 0.0f;
801 PetSpellMap::const_iterator itr = (pet->ToPet()->m_spells.find(62758));
802 if (itr == pet->ToPet()->m_spells.end())
803 itr = pet->ToPet()->m_spells.find(62762);
805 if (itr != pet->ToPet()->m_spells.end())
813 amount += ownerBonus;
842 float bonusAP = 0.0f;
844 PetSpellMap::const_iterator itr = (pet->ToPet()->m_spells.find(62758));
845 if (itr == pet->ToPet()->m_spells.end())
848 if (itr != pet->ToPet()->m_spells.end())
872 float bonusDamage = 0.0f;
874 PetSpellMap::const_iterator itr = (pet->ToPet()->m_spells.find(62758));
875 if (itr == pet->ToPet()->m_spells.end())
878 if (itr != pet->ToPet()->m_spells.end())
886 amount += bonusDamage;
936 float ownerBonus = 0.0f;
940 amount += ownerBonus;
955 float ownerBonus = 0.0f;
959 amount += ownerBonus;
974 float ownerBonus = 0.0f;
978 amount += ownerBonus;
1023 float ownerBonus = 0.0f;
1027 amount += ownerBonus;
1042 float ownerBonus = 0.0f;
1046 amount += ownerBonus;
1061 float ownerBonus = 0.0f;
1065 amount += ownerBonus;
1106 float HitMelee = 0.0f;
1112 amount +=
int32(HitMelee);
1123 float HitSpell = 0.0f;
1129 amount +=
int32(HitSpell);
1140 float Expertise = 0.0f;
1146 amount +=
int32(Expertise);
1187 float CritSpell = 0.0f;
1197 amount += (CritSpell * 0.8f);
1208 float CritMelee = 0.0f;
1218 amount += (CritMelee * 0.8f);
1259 amount -= cobraReflexes->GetAmount();
1296 if (pet->IsGuardian())
1305 mod += aurEff->GetSpellInfo()->Effects[
EFFECT_1].CalcValue() / 100;
1308 float ownerBonus = float(owner->GetStat(
STAT_STAMINA)) * mod;
1309 amount += ownerBonus;
1332 if (!pet->IsGuardian())
1350 amount += ownerBonus;
1395 float HasteMelee = 0.0f;
1399 amount +=
int32(HasteMelee);
1438 float HitMelee = 0.0f;
1444 amount +=
int32(HitMelee);
1455 float HitSpell = 0.0f;
1461 amount +=
int32(HitSpell);
1502 if (pet->IsGuardian())
1516 float HasteMelee = 0.0f;
1520 amount +=
int32(HasteMelee);
@ SPELLFAMILY_DEATHKNIGHT
@ SPELL_AURA_MOD_TOTAL_STAT_PERCENTAGE
@ SPELL_AURA_MOD_ATTACK_POWER
@ SPELL_AURA_MOD_SPELL_HIT_CHANCE
@ SPELL_AURA_MOD_RESISTANCE
@ SPELL_AURA_MOD_EXPERTISE
@ SPELL_AURA_MOD_SPELL_CRIT_CHANCE
@ SPELL_AURA_MOD_HIT_CHANCE
@ SPELL_AURA_MOD_DAMAGE_PERCENT_DONE
@ SPELL_AURA_MOD_CRIT_PCT
@ SPELL_AURA_MOD_WEAPON_CRIT_PERCENT
@ SPELL_AURA_MOD_DAMAGE_DONE
@ AURA_EFFECT_HANDLE_CHANGE_AMOUNT_MASK
#define AuraEffectCalcAmountFn(F, I, N)
#define AuraEffectApplyFn(F, I, N, M)
#define AuraEffectRemoveFn(F, I, N, M)
@ PLAYER_FIELD_MOD_DAMAGE_DONE_POS
@ PLAYER_FIELD_MOD_DAMAGE_DONE_NEG
T CalculatePct(T base, U pct)
SpellInfo const * GetSpellInfo() const
WorldObject * GetOwner() const
HookList< EffectApplyHandler > AfterEffectApply
HookList< EffectCalcAmountHandler > DoEffectCalcAmount
HookList< EffectApplyHandler > OnEffectRemove
Unit * GetUnitOwner() const
Player * GetOwner() const
int32 CalcValue(Unit const *caster=NULL, int32 const *basePoints=NULL, Unit const *target=NULL) const
SpellEffectInfo Effects[MAX_SPELL_EFFECTS]
SpellScriptLoader(const char *name)
uint32 GetResistance(SpellSchools school) const
uint32 CalculateDamage(WeaponAttackType attType, bool normalized, bool addTotalPct)
AuraEffect * GetAuraEffect(uint32 spellId, uint8 effIndex, uint64 casterGUID=0) const
float GetStat(Stats stat) const
float GetTotalAttackPowerValue(WeaponAttackType attType) const
void RemoveEffect(AuraEffect const *, AuraEffectHandleModes)
void CalculateStaminaAmount(AuraEffect const *, int32 &amount, bool &)
void ApplyEffect(AuraEffect const *, AuraEffectHandleModes)
void CalculateStrengthAmount(AuraEffect const *, int32 &amount, bool &)
PrepareAuraScript(spell_dk_pet_scaling_01_AuraScript)
spell_dk_pet_scaling_01()
AuraScript * GetAuraScript() const OVERRIDE
void CalculateAmountMeleeHaste(AuraEffect const *, int32 &amount, bool &)
PrepareAuraScript(spell_dk_pet_scaling_02_AuraScript)
AuraScript * GetAuraScript() const OVERRIDE
spell_dk_pet_scaling_02()
void CalculateAmountMeleeHit(AuraEffect const *, int32 &amount, bool &)
void CalculateAmountSpellHit(AuraEffect const *, int32 &amount, bool &)
PrepareAuraScript(spell_dk_pet_scaling_03_AuraScript)
AuraScript * GetAuraScript() const OVERRIDE
spell_dk_pet_scaling_03()
void CalculateDamageDoneAmount(AuraEffect const *, int32 &amount, bool &)
void CalculateAmountMeleeHaste(AuraEffect const *, int32 &amount, bool &)
PrepareAuraScript(spell_dk_rune_weapon_scaling_02_AuraScript)
spell_dk_rune_weapon_scaling_02()
AuraScript * GetAuraScript() const OVERRIDE
void CalculateAmountCritMelee(AuraEffect const *, int32 &amount, bool &)
void CalculateAmountExpertise(AuraEffect const *, int32 &amount, bool &)
void CalculateAmountSpellHit(AuraEffect const *, int32 &amount, bool &)
PrepareAuraScript(spell_gen_pet_calculate_AuraScript)
void CalculateAmountCritSpell(AuraEffect const *, int32 &amount, bool &)
void CalculateAmountMeleeHit(AuraEffect const *, int32 &amount, bool &)
AuraScript * GetAuraScript() const OVERRIDE
spell_gen_pet_calculate()
PrepareAuraScript(spell_hun_pet_passive_crit_AuraScript)
void CalculateAmountCritSpell(AuraEffect const *, int32 &amount, bool &)
void CalculateAmountCritMelee(AuraEffect const *, int32 &amount, bool &)
spell_hun_pet_passive_crit()
AuraScript * GetAuraScript() const OVERRIDE
PrepareAuraScript(spell_hun_pet_passive_damage_done_AuraScript)
void CalculateAmountDamageDone(AuraEffect const *, int32 &amount, bool &)
AuraScript * GetAuraScript() const OVERRIDE
spell_hun_pet_passive_damage_done()
void CalculateStaminaAmount(AuraEffect const *, int32 &amount, bool &)
void RemoveEffect(AuraEffect const *, AuraEffectHandleModes)
void ApplyEffect(AuraEffect const *, AuraEffectHandleModes)
void CalculateDamageDoneAmount(AuraEffect const *, int32 &amount, bool &)
void CalculateAttackPowerAmount(AuraEffect const *, int32 &amount, bool &)
PrepareAuraScript(spell_hun_pet_scaling_01_AuraScript)
spell_hun_pet_scaling_01()
AuraScript * GetAuraScript() const OVERRIDE
PrepareAuraScript(spell_hun_pet_scaling_02_AuraScript)
void CalculateFireResistanceAmount(AuraEffect const *, int32 &amount, bool &)
void CalculateFrostResistanceAmount(AuraEffect const *, int32 &amount, bool &)
void CalculateNatureResistanceAmount(AuraEffect const *, int32 &amount, bool &)
AuraScript * GetAuraScript() const OVERRIDE
spell_hun_pet_scaling_02()
void CalculateArcaneResistanceAmount(AuraEffect const *, int32 &amount, bool &)
void CalculateArmorAmount(AuraEffect const *, int32 &amount, bool &)
void CalculateShadowResistanceAmount(AuraEffect const *, int32 &amount, bool &)
PrepareAuraScript(spell_hun_pet_scaling_03_AuraScript)
AuraScript * GetAuraScript() const OVERRIDE
spell_hun_pet_scaling_03()
PrepareAuraScript(spell_hun_pet_scaling_04_AuraScript)
void CalculateAmountMeleeHit(AuraEffect const *, int32 &amount, bool &)
void CalculateAmountSpellHit(AuraEffect const *, int32 &amount, bool &)
void CalculateAmountExpertise(AuraEffect const *, int32 &amount, bool &)
spell_hun_pet_scaling_04()
AuraScript * GetAuraScript() const OVERRIDE
PrepareAuraScript(spell_sha_pet_scaling_04_AuraScript)
void CalculateAmountMeleeHit(AuraEffect const *, int32 &amount, bool &)
void CalculateAmountSpellHit(AuraEffect const *, int32 &amount, bool &)
AuraScript * GetAuraScript() const OVERRIDE
spell_sha_pet_scaling_04()
void CalculateAmountCritSpell(AuraEffect const *, int32 &amount, bool &)
PrepareAuraScript(spell_warl_pet_passive_AuraScript)
void CalculateAmountCritMelee(AuraEffect const *, int32 &amount, bool &)
PrepareAuraScript(spell_warl_pet_passive_damage_done_AuraScript)
void CalculateAmountDamageDone(AuraEffect const *, int32 &amount, bool &)
AuraScript * GetAuraScript() const OVERRIDE
spell_warl_pet_passive_damage_done()
AuraScript * GetAuraScript() const OVERRIDE
void CalculateDamageDoneAmount(AuraEffect const *, int32 &amount, bool &)
void RemoveEffect(AuraEffect const *, AuraEffectHandleModes)
void ApplyEffect(AuraEffect const *, AuraEffectHandleModes)
void CalculateAttackPowerAmount(AuraEffect const *, int32 &amount, bool &)
void CalculateStaminaAmount(AuraEffect const *, int32 &amount, bool &)
PrepareAuraScript(spell_warl_pet_scaling_01_AuraScript)
AuraScript * GetAuraScript() const OVERRIDE
spell_warl_pet_scaling_01()
void CalculateFireResistanceAmount(AuraEffect const *, int32 &amount, bool &)
void RemoveEffect(AuraEffect const *, AuraEffectHandleModes)
void CalculateIntellectAmount(AuraEffect const *, int32 &amount, bool &)
void CalculateArmorAmount(AuraEffect const *, int32 &amount, bool &)
PrepareAuraScript(spell_warl_pet_scaling_02_AuraScript)
void ApplyEffect(AuraEffect const *, AuraEffectHandleModes)
spell_warl_pet_scaling_02()
AuraScript * GetAuraScript() const OVERRIDE
PrepareAuraScript(spell_warl_pet_scaling_03_AuraScript)
void CalculateArcaneResistanceAmount(AuraEffect const *, int32 &amount, bool &)
void CalculateFrostResistanceAmount(AuraEffect const *, int32 &amount, bool &)
void CalculateNatureResistanceAmount(AuraEffect const *, int32 &amount, bool &)
AuraScript * GetAuraScript() const OVERRIDE
spell_warl_pet_scaling_03()
PrepareAuraScript(spell_warl_pet_scaling_04_AuraScript)
void CalculateShadowResistanceAmount(AuraEffect const *, int32 &amount, bool &)
AuraScript * GetAuraScript() const OVERRIDE
spell_warl_pet_scaling_04()
void CalculateAmountExpertise(AuraEffect const *, int32 &amount, bool &)
PrepareAuraScript(spell_warl_pet_scaling_05_AuraScript)
void CalculateAmountSpellHit(AuraEffect const *, int32 &amount, bool &)
void CalculateAmountMeleeHit(AuraEffect const *, int32 &amount, bool &)
AuraScript * GetAuraScript() const OVERRIDE
spell_warl_pet_scaling_05()
@ SPELL_DEATH_KNIGHT_RUNE_WEAPON_02
@ SPELL_DEATH_KNIGHT_PET_SCALING_02
@ SPELL_DEATH_KNIGHT_PET_SCALING_03
@ SPELL_DEATH_KNIGHT_PET_SCALING_01
@ ENTRY_ARMY_OF_THE_DEAD_GHOUL
@ SPELL_PET_PASSIVE_DAMAGE_TAKEN
@ SPELL_TAMED_PET_PASSIVE_07
@ SPELL_HUNTER_PET_SCALING_01
void AddSC_pet_spell_scripts()