Merge remote-tracking branch 'origin/master' into 4.3.4
Conflicts: dep/PackageList.txt src/server/game/Battlegrounds/Battleground.cpp src/server/game/Combat/ThreatManager.cpp src/server/game/Entities/Object/Object.cpp src/server/game/Entities/Player/Player.cpp src/server/game/Entities/Unit/Unit.cpp src/server/game/Handlers/BattleGroundHandler.cpp src/server/game/Movement/MovementGenerators/RandomMovementGenerator.cpp src/server/game/Movement/MovementGenerators/TargetedMovementGenerator.cpp src/server/game/Movement/Spline/MoveSplineInit.cpp src/server/game/Spells/Auras/SpellAuraEffects.cpp src/server/game/Spells/SpellEffects.cpp src/server/game/World/World.cpp src/server/game/World/World.h src/server/scripts/EasternKingdoms/ZulGurub/boss_arlokk.cpp src/server/scripts/EasternKingdoms/ZulGurub/instance_zulgurub.cpp src/server/scripts/EasternKingdoms/ZulGurub/zulgurub.h src/server/scripts/Spells/spell_druid.cpp src/server/scripts/Spells/spell_mage.cpp src/server/scripts/Spells/spell_paladin.cpp src/server/scripts/Spells/spell_priest.cpp src/server/scripts/Spells/spell_rogue.cpp src/server/scripts/Spells/spell_shaman.cpp src/server/scripts/Spells/spell_warlock.cpp src/server/scripts/Spells/spell_warrior.cpp src/tools/map_extractor/CMakeLists.txt src/tools/map_extractor/System.cpp src/tools/map_extractor/loadlib.cpp src/tools/map_extractor/mpq_libmpq.cpp src/tools/map_extractor/mpq_libmpq04.h src/tools/vmap4_assembler/CMakeLists.txt src/tools/vmap4_extractor/CMakeLists.txt src/tools/vmap4_extractor/mpq_libmpq.cpp src/tools/vmap4_extractor/mpq_libmpq04.h
This commit is contained in:
commit
b404e0bec1
274 files changed
+28968
-2768
No files matched your search
@@ -39,10 +39,15 @@ enum DruidSpells
|
||||
SPELL_DRUID_SOLAR_ECLIPSE = 48517,
|
||||
SPELL_DRUID_LUNAR_ECLIPSE = 48518,
|
||||
SPELL_DRUID_ENRAGE_MOD_DAMAGE = 51185,
|
||||
SPELL_DRUID_GLYPH_OF_TYPHOON = 62135,
|
||||
SPELL_DRUID_IDOL_OF_FERAL_SHADOWS = 34241,
|
||||
SPELL_DRUID_IDOL_OF_WORSHIP = 60774,
|
||||
SPELL_DRUID_INCREASED_MOONFIRE_DURATION = 38414,
|
||||
SPELL_DRUID_KING_OF_THE_JUNGLE = 48492,
|
||||
SPELL_DRUID_LIFEBLOOM_ENERGIZE = 64372,
|
||||
SPELL_DRUID_LIFEBLOOM_FINAL_HEAL = 33778,
|
||||
SPELL_DRUID_LIVING_SEED_HEAL = 48503,
|
||||
SPELL_DRUID_LIVING_SEED_PROC = 48504,
|
||||
SPELL_DRUID_NATURES_SPLENDOR = 57865,
|
||||
SPELL_DRUID_SURVIVAL_INSTINCTS = 50322,
|
||||
SPELL_DRUID_SAVAGE_ROAR = 62071,
|
||||
@@ -160,6 +165,35 @@ class spell_dru_eclipse_energize : public SpellScriptLoader
|
||||
}
|
||||
};
|
||||
|
||||
// -1850 - Dash
|
||||
class spell_dru_dash : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_dru_dash() : SpellScriptLoader("spell_dru_dash") { }
|
||||
|
||||
class spell_dru_dash_AuraScript : public AuraScript
|
||||
{
|
||||
PrepareAuraScript(spell_dru_dash_AuraScript);
|
||||
|
||||
void CalculateAmount(AuraEffect const* /*aurEff*/, int32& amount, bool& /*canBeRecalculated*/)
|
||||
{
|
||||
// do not set speed if not in cat form
|
||||
if (GetUnitOwner()->GetShapeshiftForm() != FORM_CAT)
|
||||
amount = 0;
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_dru_dash_AuraScript::CalculateAmount, EFFECT_0, SPELL_AURA_MOD_INCREASE_SPEED);
|
||||
}
|
||||
};
|
||||
|
||||
AuraScript* GetAuraScript() const
|
||||
{
|
||||
return new spell_dru_dash_AuraScript();
|
||||
}
|
||||
};
|
||||
|
||||
// -5229 - Enrage
|
||||
class spell_dru_enrage : public SpellScriptLoader
|
||||
{
|
||||
@@ -240,6 +274,69 @@ class spell_dru_glyph_of_starfire : public SpellScriptLoader
|
||||
}
|
||||
};
|
||||
|
||||
// 34246 - Idol of the Emerald Queen
|
||||
// 60779 - Idol of Lush Moss
|
||||
class spell_dru_idol_lifebloom : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_dru_idol_lifebloom() : SpellScriptLoader("spell_dru_idol_lifebloom") { }
|
||||
|
||||
class spell_dru_idol_lifebloom_AuraScript : public AuraScript
|
||||
{
|
||||
PrepareAuraScript(spell_dru_idol_lifebloom_AuraScript);
|
||||
|
||||
void HandleEffectCalcSpellMod(AuraEffect const* aurEff, SpellModifier*& spellMod)
|
||||
{
|
||||
if (!spellMod)
|
||||
{
|
||||
spellMod = new SpellModifier(GetAura());
|
||||
spellMod->op = SPELLMOD_DOT;
|
||||
spellMod->type = SPELLMOD_FLAT;
|
||||
spellMod->spellId = GetId();
|
||||
spellMod->mask = GetSpellInfo()->Effects[aurEff->GetEffIndex()].SpellClassMask;
|
||||
}
|
||||
spellMod->value = aurEff->GetAmount() / 7;
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
DoEffectCalcSpellMod += AuraEffectCalcSpellModFn(spell_dru_idol_lifebloom_AuraScript::HandleEffectCalcSpellMod, EFFECT_0, SPELL_AURA_DUMMY);
|
||||
}
|
||||
};
|
||||
|
||||
AuraScript* GetAuraScript() const
|
||||
{
|
||||
return new spell_dru_idol_lifebloom_AuraScript();
|
||||
}
|
||||
};
|
||||
|
||||
// 29166 - Innervate
|
||||
class spell_dru_innervate : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_dru_innervate() : SpellScriptLoader("spell_dru_innervate") { }
|
||||
|
||||
class spell_dru_innervate_AuraScript : public AuraScript
|
||||
{
|
||||
PrepareAuraScript(spell_dru_innervate_AuraScript);
|
||||
|
||||
void CalculateAmount(AuraEffect const* aurEff, int32& amount, bool& /*canBeRecalculated*/)
|
||||
{
|
||||
amount = CalculatePct(int32(GetUnitOwner()->GetCreatePowers(POWER_MANA) / aurEff->GetTotalTicks()), amount);
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_dru_innervate_AuraScript::CalculateAmount, EFFECT_0, SPELL_AURA_PERIODIC_ENERGIZE);
|
||||
}
|
||||
};
|
||||
|
||||
AuraScript* GetAuraScript() const
|
||||
{
|
||||
return new spell_dru_innervate_AuraScript();
|
||||
}
|
||||
};
|
||||
|
||||
// -5570 - Insect Swarm
|
||||
class spell_dru_insect_swarm : public SpellScriptLoader
|
||||
{
|
||||
@@ -351,6 +448,77 @@ class spell_dru_lifebloom : public SpellScriptLoader
|
||||
}
|
||||
};
|
||||
|
||||
// -48496 - Living Seed
|
||||
class spell_dru_living_seed : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_dru_living_seed() : SpellScriptLoader("spell_dru_living_seed") { }
|
||||
|
||||
class spell_dru_living_seed_AuraScript : public AuraScript
|
||||
{
|
||||
PrepareAuraScript(spell_dru_living_seed_AuraScript);
|
||||
|
||||
bool Validate(SpellInfo const* /*spellInfo*/)
|
||||
{
|
||||
if (!sSpellMgr->GetSpellInfo(SPELL_DRUID_LIVING_SEED_PROC))
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
void HandleProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo)
|
||||
{
|
||||
PreventDefaultAction();
|
||||
int32 amount = CalculatePct(eventInfo.GetHealInfo()->GetHeal(), aurEff->GetAmount());
|
||||
GetTarget()->CastCustomSpell(SPELL_DRUID_LIVING_SEED_PROC, SPELLVALUE_BASE_POINT0, amount, eventInfo.GetProcTarget(), true, NULL, aurEff);
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
OnEffectProc += AuraEffectProcFn(spell_dru_living_seed_AuraScript::HandleProc, EFFECT_0, SPELL_AURA_DUMMY);
|
||||
}
|
||||
};
|
||||
|
||||
AuraScript* GetAuraScript() const
|
||||
{
|
||||
return new spell_dru_living_seed_AuraScript();
|
||||
}
|
||||
};
|
||||
|
||||
// 48504 - Living Seed (Proc)
|
||||
class spell_dru_living_seed_proc : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_dru_living_seed_proc() : SpellScriptLoader("spell_dru_living_seed_proc") { }
|
||||
|
||||
class spell_dru_living_seed_proc_AuraScript : public AuraScript
|
||||
{
|
||||
PrepareAuraScript(spell_dru_living_seed_proc_AuraScript);
|
||||
|
||||
bool Validate(SpellInfo const* /*spellInfo*/)
|
||||
{
|
||||
if (!sSpellMgr->GetSpellInfo(SPELL_DRUID_LIVING_SEED_HEAL))
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
void HandleProc(AuraEffect const* aurEff, ProcEventInfo& /*eventInfo*/)
|
||||
{
|
||||
PreventDefaultAction();
|
||||
GetTarget()->CastCustomSpell(SPELL_DRUID_LIVING_SEED_HEAL, SPELLVALUE_BASE_POINT0, aurEff->GetAmount(), GetTarget(), true, NULL, aurEff);
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
OnEffectProc += AuraEffectProcFn(spell_dru_living_seed_proc_AuraScript::HandleProc, EFFECT_0, SPELL_AURA_DUMMY);
|
||||
}
|
||||
};
|
||||
|
||||
AuraScript* GetAuraScript() const
|
||||
{
|
||||
return new spell_dru_living_seed_proc_AuraScript();
|
||||
}
|
||||
};
|
||||
|
||||
// 69366 - Moonkin Form passive
|
||||
class spell_dru_moonkin_form_passive : public SpellScriptLoader
|
||||
{
|
||||
@@ -395,6 +563,33 @@ class spell_dru_moonkin_form_passive : public SpellScriptLoader
|
||||
}
|
||||
};
|
||||
|
||||
// 48391 - Owlkin Frenzy
|
||||
class spell_dru_owlkin_frenzy : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_dru_owlkin_frenzy() : SpellScriptLoader("spell_dru_owlkin_frenzy") { }
|
||||
|
||||
class spell_dru_owlkin_frenzy_AuraScript : public AuraScript
|
||||
{
|
||||
PrepareAuraScript(spell_dru_owlkin_frenzy_AuraScript);
|
||||
|
||||
void CalculateAmount(AuraEffect const* /*aurEff*/, int32& amount, bool& /*canBeRecalculated*/)
|
||||
{
|
||||
amount = CalculatePct(GetUnitOwner()->GetCreatePowers(POWER_MANA), amount);
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_dru_owlkin_frenzy_AuraScript::CalculateAmount, EFFECT_2, SPELL_AURA_PERIODIC_ENERGIZE);
|
||||
}
|
||||
};
|
||||
|
||||
AuraScript* GetAuraScript() const
|
||||
{
|
||||
return new spell_dru_owlkin_frenzy_AuraScript();
|
||||
}
|
||||
};
|
||||
|
||||
// -16972 - Predatory Strikes
|
||||
class spell_dru_predatory_strikes : public SpellScriptLoader
|
||||
{
|
||||
@@ -468,6 +663,54 @@ class spell_dru_primal_tenacity : public SpellScriptLoader
|
||||
}
|
||||
};
|
||||
|
||||
// -1079 - Rip
|
||||
class spell_dru_rip : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_dru_rip() : SpellScriptLoader("spell_dru_rip") { }
|
||||
|
||||
class spell_dru_rip_AuraScript : public AuraScript
|
||||
{
|
||||
PrepareAuraScript(spell_dru_rip_AuraScript);
|
||||
|
||||
bool Load()
|
||||
{
|
||||
Unit* caster = GetCaster();
|
||||
return caster && caster->GetTypeId() == TYPEID_PLAYER;
|
||||
}
|
||||
|
||||
void CalculateAmount(AuraEffect const* /*aurEff*/, int32& amount, bool& canBeRecalculated)
|
||||
{
|
||||
canBeRecalculated = false;
|
||||
|
||||
if (Unit* caster = GetCaster())
|
||||
{
|
||||
// 0.01 * $AP * cp
|
||||
uint8 cp = caster->ToPlayer()->GetComboPoints();
|
||||
|
||||
// Idol of Feral Shadows. Can't be handled as SpellMod due its dependency from CPs
|
||||
if (AuraEffect const* idol = caster->GetAuraEffect(SPELL_DRUID_IDOL_OF_FERAL_SHADOWS, EFFECT_0))
|
||||
amount += cp * idol->GetAmount();
|
||||
// Idol of Worship. Can't be handled as SpellMod due its dependency from CPs
|
||||
else if (AuraEffect const* idol = caster->GetAuraEffect(SPELL_DRUID_IDOL_OF_WORSHIP, EFFECT_0))
|
||||
amount += cp * idol->GetAmount();
|
||||
|
||||
amount += int32(CalculatePct(caster->GetTotalAttackPowerValue(BASE_ATTACK), cp));
|
||||
}
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_dru_rip_AuraScript::CalculateAmount, EFFECT_0, SPELL_AURA_PERIODIC_DAMAGE);
|
||||
}
|
||||
};
|
||||
|
||||
AuraScript* GetAuraScript() const
|
||||
{
|
||||
return new spell_dru_rip_AuraScript();
|
||||
}
|
||||
};
|
||||
|
||||
// 62606 - Savage Defense
|
||||
class spell_dru_savage_defense : public SpellScriptLoader
|
||||
{
|
||||
@@ -777,6 +1020,35 @@ class spell_dru_tiger_s_fury : public SpellScriptLoader
|
||||
}
|
||||
};
|
||||
|
||||
// -61391 - Typhoon
|
||||
class spell_dru_typhoon : public SpellScriptLoader
|
||||
{
|
||||
public:
|
||||
spell_dru_typhoon() : SpellScriptLoader("spell_dru_typhoon") { }
|
||||
|
||||
class spell_dru_typhoon_SpellScript : public SpellScript
|
||||
{
|
||||
PrepareSpellScript(spell_dru_typhoon_SpellScript);
|
||||
|
||||
void HandleKnockBack(SpellEffIndex effIndex)
|
||||
{
|
||||
// Glyph of Typhoon
|
||||
if (GetCaster()->HasAura(SPELL_DRUID_GLYPH_OF_TYPHOON))
|
||||
PreventHitDefaultEffect(effIndex);
|
||||
}
|
||||
|
||||
void Register()
|
||||
{
|
||||
OnEffectHitTarget += SpellEffectFn(spell_dru_typhoon_SpellScript::HandleKnockBack, EFFECT_0, SPELL_EFFECT_KNOCK_BACK);
|
||||
}
|
||||
};
|
||||
|
||||
SpellScript* GetSpellScript() const
|
||||
{
|
||||
return new spell_dru_typhoon_SpellScript();
|
||||
}
|
||||
};
|
||||
|
||||
// 70691 - Item T10 Restoration 4P Bonus
|
||||
class spell_dru_t10_restoration_4p_bonus : public SpellScriptLoader
|
||||
{
|
||||
@@ -834,14 +1106,21 @@ class spell_dru_t10_restoration_4p_bonus : public SpellScriptLoader
|
||||
|
||||
void AddSC_druid_spell_scripts()
|
||||
{
|
||||
new spell_dru_dash();
|
||||
new spell_dru_eclipse_energize();
|
||||
new spell_dru_enrage();
|
||||
new spell_dru_glyph_of_starfire();
|
||||
new spell_dru_idol_lifebloom();
|
||||
new spell_dru_innervate();
|
||||
new spell_dru_insect_swarm();
|
||||
new spell_dru_lifebloom();
|
||||
new spell_dru_living_seed();
|
||||
new spell_dru_living_seed_proc();
|
||||
new spell_dru_moonkin_form_passive();
|
||||
new spell_dru_owlkin_frenzy();
|
||||
new spell_dru_predatory_strikes();
|
||||
new spell_dru_primal_tenacity();
|
||||
new spell_dru_rip();
|
||||
new spell_dru_savage_defense();
|
||||
new spell_dru_savage_roar();
|
||||
new spell_dru_starfall_aoe();
|
||||
@@ -849,5 +1128,6 @@ void AddSC_druid_spell_scripts()
|
||||
new spell_dru_survival_instincts();
|
||||
new spell_dru_swift_flight_passive();
|
||||
new spell_dru_tiger_s_fury();
|
||||
new spell_dru_typhoon();
|
||||
new spell_dru_t10_restoration_4p_bonus();
|
||||
}
|
||||
Reference in new issue
Block a user