diff options
| author | Nay <dnpd.dd@gmail.com> | 2013-07-14 16:10:20 +0100 |
|---|---|---|
| committer | Nay <dnpd.dd@gmail.com> | 2013-07-14 16:10:20 +0100 |
| commit | b56b282eeeba5e21bc256c2ce2ff27edef5f08d9 (patch) | |
| tree | 4cddec28bf8323dce18e451bf038c2bba6071c6b /src/server/scripts/Outland/GruulsLair | |
| parent | f8ba2c066bc3dacafa98556aeabbfab04fc5f583 (diff) | |
| parent | bedb2e56e2ca35ad6790c2ef2c736a88b8f1fb16 (diff) | |
Merge remote-tracking branch 'origin/master' into 4.3.4
Conflicts:
src/server/game/Entities/Creature/GossipDef.cpp
src/server/game/Entities/Player/Player.cpp
src/server/game/Entities/Player/Player.h
src/server/game/Handlers/QuestHandler.cpp
src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp
src/server/scripts/EasternKingdoms/ZulAman/boss_halazzi.cpp
src/server/scripts/EasternKingdoms/ZulAman/boss_hexlord.cpp
src/server/scripts/EasternKingdoms/ZulAman/boss_janalai.cpp
src/server/scripts/EasternKingdoms/ZulAman/boss_nalorakk.cpp
src/server/scripts/EasternKingdoms/ZulAman/boss_zuljin.cpp
src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp
src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp
src/server/scripts/EasternKingdoms/ZulGurub/boss_arlokk.cpp
src/server/scripts/EasternKingdoms/ZulGurub/boss_grilek.cpp
src/server/scripts/EasternKingdoms/ZulGurub/boss_hakkar.cpp
src/server/scripts/EasternKingdoms/ZulGurub/boss_hazzarah.cpp
src/server/scripts/EasternKingdoms/ZulGurub/boss_jeklik.cpp
src/server/scripts/EasternKingdoms/ZulGurub/boss_jindo.cpp
src/server/scripts/EasternKingdoms/ZulGurub/boss_kilnara.cpp
src/server/scripts/EasternKingdoms/ZulGurub/boss_mandokir.cpp
src/server/scripts/EasternKingdoms/ZulGurub/boss_marli.cpp
src/server/scripts/EasternKingdoms/ZulGurub/boss_renataki.cpp
src/server/scripts/EasternKingdoms/ZulGurub/boss_thekal.cpp
src/server/scripts/EasternKingdoms/ZulGurub/boss_venoxis.cpp
src/server/scripts/EasternKingdoms/ZulGurub/boss_wushoolay.cpp
src/server/scripts/EasternKingdoms/ZulGurub/instance_zulgurub.cpp
src/server/scripts/EasternKingdoms/boss_kruul.cpp
src/server/scripts/EasternKingdoms/zone_arathi_highlands.cpp
src/server/scripts/EasternKingdoms/zone_burning_steppes.cpp
src/server/scripts/EasternKingdoms/zone_ghostlands.cpp
src/server/scripts/EasternKingdoms/zone_hinterlands.cpp
src/server/scripts/EasternKingdoms/zone_ironforge.cpp
src/server/scripts/EasternKingdoms/zone_loch_modan.cpp
src/server/scripts/EasternKingdoms/zone_redridge_mountains.cpp
src/server/scripts/EasternKingdoms/zone_silverpine_forest.cpp
src/server/scripts/EasternKingdoms/zone_stormwind_city.cpp
src/server/scripts/EasternKingdoms/zone_swamp_of_sorrows.cpp
src/server/scripts/EasternKingdoms/zone_tirisfal_glades.cpp
src/server/scripts/Kalimdor/zone_azshara.cpp
src/server/scripts/Kalimdor/zone_darkshore.cpp
src/server/scripts/Kalimdor/zone_desolace.cpp
src/server/scripts/Kalimdor/zone_durotar.cpp
src/server/scripts/Kalimdor/zone_felwood.cpp
src/server/scripts/Kalimdor/zone_feralas.cpp
src/server/scripts/Kalimdor/zone_mulgore.cpp
src/server/scripts/Kalimdor/zone_orgrimmar.cpp
src/server/scripts/Kalimdor/zone_stonetalon_mountains.cpp
src/server/scripts/Kalimdor/zone_tanaris.cpp
src/server/scripts/Kalimdor/zone_thousand_needles.cpp
src/server/scripts/Kalimdor/zone_thunder_bluff.cpp
src/server/scripts/Kalimdor/zone_ungoro_crater.cpp
src/server/scripts/Northrend/zone_dalaran.cpp
src/server/scripts/OutdoorPvP/OutdoorPvPEP.cpp
src/server/scripts/Spells/spell_druid.cpp
src/server/scripts/Spells/spell_generic.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_shaman.cpp
src/server/scripts/Spells/spell_warlock.cpp
src/server/scripts/Spells/spell_warrior.cpp
src/server/scripts/World/item_scripts.cpp
Diffstat (limited to 'src/server/scripts/Outland/GruulsLair')
4 files changed, 68 insertions, 62 deletions
diff --git a/src/server/scripts/Outland/GruulsLair/boss_gruul.cpp b/src/server/scripts/Outland/GruulsLair/boss_gruul.cpp index 473630cc9af..31f854803bc 100644 --- a/src/server/scripts/Outland/GruulsLair/boss_gruul.cpp +++ b/src/server/scripts/Outland/GruulsLair/boss_gruul.cpp @@ -28,7 +28,7 @@ EndScriptData */ #include "SpellScript.h" #include "gruuls_lair.h" -enum eEnums +enum Yells { SAY_AGGRO = 0, SAY_SLAM = 1, @@ -36,8 +36,11 @@ enum eEnums SAY_SLAY = 3, SAY_DEATH = 4, - EMOTE_GROW = 5, + EMOTE_GROW = 5 +}; +enum Spells +{ SPELL_GROWTH = 36300, SPELL_CAVE_IN = 36240, SPELL_GROUND_SLAM = 33525, //AoE Ground Slam applying Ground Slam to everyone with a script effect (most likely the knock back, we can code it to a set knockback) @@ -57,9 +60,9 @@ class boss_gruul : public CreatureScript public: boss_gruul() : CreatureScript("boss_gruul") { } - CreatureAI* GetAI(Creature* creature) const + CreatureAI* GetAI(Creature* creature) const OVERRIDE { - return new boss_gruulAI (creature); + return new boss_gruulAI(creature); } struct boss_gruulAI : public ScriptedAI @@ -80,7 +83,7 @@ public: bool m_bPerformingGroundSlam; - void Reset() + void Reset() OVERRIDE { m_uiGrowth_Timer= 30000; m_uiCaveIn_Timer= 27000; @@ -94,7 +97,7 @@ public: instance->SetData(DATA_GRUULEVENT, NOT_STARTED); } - void EnterCombat(Unit* /*who*/) + void EnterCombat(Unit* /*who*/) OVERRIDE { Talk(SAY_AGGRO); @@ -102,12 +105,12 @@ public: instance->SetData(DATA_GRUULEVENT, IN_PROGRESS); } - void KilledUnit(Unit* /*victim*/) + void KilledUnit(Unit* /*victim*/) OVERRIDE { Talk(SAY_SLAY); } - void JustDied(Unit* /*killer*/) + void JustDied(Unit* /*killer*/) OVERRIDE { Talk(SAY_DEATH); @@ -118,7 +121,7 @@ public: } } - void SpellHitTarget(Unit* target, const SpellInfo* pSpell) + void SpellHitTarget(Unit* target, const SpellInfo* pSpell) OVERRIDE { //This to emulate effect1 (77) of SPELL_GROUND_SLAM, knock back to any direction //It's initially wrong, since this will cause fall damage, which is by comments, not intended. @@ -158,7 +161,7 @@ public: } } - void UpdateAI(uint32 uiDiff) + void UpdateAI(uint32 uiDiff) OVERRIDE { //Return since we have no target if (!UpdateVictim()) @@ -260,7 +263,7 @@ class spell_gruul_shatter : public SpellScriptLoader { PrepareSpellScript(spell_gruul_shatter_SpellScript); - bool Validate(SpellInfo const* /*spell*/) + bool Validate(SpellInfo const* /*spell*/) OVERRIDE { if (!sSpellMgr->GetSpellInfo(SPELL_STONED)) return false; @@ -278,13 +281,13 @@ class spell_gruul_shatter : public SpellScriptLoader } } - void Register() + void Register() OVERRIDE { OnEffectHitTarget += SpellEffectFn(spell_gruul_shatter_SpellScript::HandleScript, EFFECT_0, SPELL_EFFECT_SCRIPT_EFFECT); } }; - SpellScript* GetSpellScript() const + SpellScript* GetSpellScript() const OVERRIDE { return new spell_gruul_shatter_SpellScript(); } @@ -313,13 +316,13 @@ class spell_gruul_shatter_effect : public SpellScriptLoader SetHitDamage(int32(GetHitDamage() * ((radius - distance) / radius))); } - void Register() + void Register() OVERRIDE { OnHit += SpellHitFn(spell_gruul_shatter_effect_SpellScript::CalculateDamage); } }; - SpellScript* GetSpellScript() const + SpellScript* GetSpellScript() const OVERRIDE { return new spell_gruul_shatter_effect_SpellScript(); } diff --git a/src/server/scripts/Outland/GruulsLair/boss_high_king_maulgar.cpp b/src/server/scripts/Outland/GruulsLair/boss_high_king_maulgar.cpp index f927f606bda..d216c0b02ee 100644 --- a/src/server/scripts/Outland/GruulsLair/boss_high_king_maulgar.cpp +++ b/src/server/scripts/Outland/GruulsLair/boss_high_king_maulgar.cpp @@ -110,9 +110,9 @@ class boss_high_king_maulgar : public CreatureScript public: boss_high_king_maulgar() : CreatureScript("boss_high_king_maulgar") { } - CreatureAI* GetAI(Creature* creature) const + CreatureAI* GetAI(Creature* creature) const OVERRIDE { - return new boss_high_king_maulgarAI (creature); + return new boss_high_king_maulgarAI(creature); } struct boss_high_king_maulgarAI : public ScriptedAI @@ -136,7 +136,7 @@ public: uint64 Council[4]; - void Reset() + void Reset() OVERRIDE { ArcingSmash_Timer = 10000; MightyBlow_Timer = 40000; @@ -167,12 +167,12 @@ public: instance->SetData(DATA_MAULGAREVENT, NOT_STARTED); } - void KilledUnit(Unit* /*victim*/) + void KilledUnit(Unit* /*victim*/) OVERRIDE { Talk(SAY_SLAY); } - void JustDied(Unit* /*killer*/) + void JustDied(Unit* /*killer*/) OVERRIDE { Talk(SAY_DEATH); @@ -185,7 +185,7 @@ public: Talk(SAY_OGRE_DEATH); } - void EnterCombat(Unit* who) + void EnterCombat(Unit* who) OVERRIDE { StartEvent(who); } @@ -217,7 +217,7 @@ public: DoZoneInCombat(); } - void UpdateAI(uint32 diff) + void UpdateAI(uint32 diff) OVERRIDE { //Only if not incombat check if the event is started if (!me->IsInCombat() && instance && instance->GetData(DATA_MAULGAREVENT)) @@ -309,9 +309,9 @@ class boss_olm_the_summoner : public CreatureScript public: boss_olm_the_summoner() : CreatureScript("boss_olm_the_summoner") { } - CreatureAI* GetAI(Creature* creature) const + CreatureAI* GetAI(Creature* creature) const OVERRIDE { - return new boss_olm_the_summonerAI (creature); + return new boss_olm_the_summonerAI(creature); } struct boss_olm_the_summonerAI : public ScriptedAI @@ -327,7 +327,7 @@ public: InstanceScript* instance; - void Reset() + void Reset() OVERRIDE { DarkDecay_Timer = 10000; Summon_Timer = 15000; @@ -338,7 +338,7 @@ public: instance->SetData(DATA_MAULGAREVENT, NOT_STARTED); } - void AttackStart(Unit* who) + void AttackStart(Unit* who) OVERRIDE { if (!who) return; @@ -353,7 +353,7 @@ public: } } - void EnterCombat(Unit* who) + void EnterCombat(Unit* who) OVERRIDE { if (instance) { @@ -362,7 +362,7 @@ public: } } - void JustDied(Unit* /*killer*/) + void JustDied(Unit* /*killer*/) OVERRIDE { if (instance) { @@ -377,7 +377,7 @@ public: } } - void UpdateAI(uint32 diff) + void UpdateAI(uint32 diff) OVERRIDE { //Only if not incombat check if the event is started if (!me->IsInCombat() && instance && instance->GetData(DATA_MAULGAREVENT)) @@ -437,9 +437,9 @@ class boss_kiggler_the_crazed : public CreatureScript public: boss_kiggler_the_crazed() : CreatureScript("boss_kiggler_the_crazed") { } - CreatureAI* GetAI(Creature* creature) const + CreatureAI* GetAI(Creature* creature) const OVERRIDE { - return new boss_kiggler_the_crazedAI (creature); + return new boss_kiggler_the_crazedAI(creature); } struct boss_kiggler_the_crazedAI : public ScriptedAI @@ -456,7 +456,7 @@ public: InstanceScript* instance; - void Reset() + void Reset() OVERRIDE { GreaterPolymorph_Timer = 5000; LightningBolt_Timer = 10000; @@ -468,7 +468,7 @@ public: instance->SetData(DATA_MAULGAREVENT, NOT_STARTED); } - void EnterCombat(Unit* who) + void EnterCombat(Unit* who) OVERRIDE { if (instance) { @@ -477,7 +477,7 @@ public: } } - void JustDied(Unit* /*killer*/) + void JustDied(Unit* /*killer*/) OVERRIDE { if (instance) { @@ -492,7 +492,7 @@ public: } } - void UpdateAI(uint32 diff) + void UpdateAI(uint32 diff) OVERRIDE { //Only if not incombat check if the event is started if (!me->IsInCombat() && instance && instance->GetData(DATA_MAULGAREVENT)) @@ -558,9 +558,9 @@ class boss_blindeye_the_seer : public CreatureScript public: boss_blindeye_the_seer() : CreatureScript("boss_blindeye_the_seer") { } - CreatureAI* GetAI(Creature* creature) const + CreatureAI* GetAI(Creature* creature) const OVERRIDE { - return new boss_blindeye_the_seerAI (creature); + return new boss_blindeye_the_seerAI(creature); } struct boss_blindeye_the_seerAI : public ScriptedAI @@ -576,7 +576,7 @@ public: InstanceScript* instance; - void Reset() + void Reset() OVERRIDE { GreaterPowerWordShield_Timer = 5000; Heal_Timer = urand(25000, 40000); @@ -587,7 +587,7 @@ public: instance->SetData(DATA_MAULGAREVENT, NOT_STARTED); } - void EnterCombat(Unit* who) + void EnterCombat(Unit* who) OVERRIDE { if (instance) { @@ -596,7 +596,7 @@ public: } } - void JustDied(Unit* /*killer*/) + void JustDied(Unit* /*killer*/) OVERRIDE { if (instance) { @@ -611,7 +611,7 @@ public: } } - void UpdateAI(uint32 diff) + void UpdateAI(uint32 diff) OVERRIDE { //Only if not incombat check if the event is started if (!me->IsInCombat() && instance && instance->GetData(DATA_MAULGAREVENT)) @@ -668,9 +668,9 @@ class boss_krosh_firehand : public CreatureScript public: boss_krosh_firehand() : CreatureScript("boss_krosh_firehand") { } - CreatureAI* GetAI(Creature* creature) const + CreatureAI* GetAI(Creature* creature) const OVERRIDE { - return new boss_krosh_firehandAI (creature); + return new boss_krosh_firehandAI(creature); } struct boss_krosh_firehandAI : public ScriptedAI @@ -686,7 +686,7 @@ public: InstanceScript* instance; - void Reset() + void Reset() OVERRIDE { GreaterFireball_Timer = 1000; SpellShield_Timer = 5000; @@ -697,7 +697,7 @@ public: instance->SetData(DATA_MAULGAREVENT, NOT_STARTED); } - void EnterCombat(Unit* who) + void EnterCombat(Unit* who) OVERRIDE { if (instance) { @@ -706,7 +706,7 @@ public: } } - void JustDied(Unit* /*killer*/) + void JustDied(Unit* /*killer*/) OVERRIDE { if (instance) { @@ -721,7 +721,7 @@ public: } } - void UpdateAI(uint32 diff) + void UpdateAI(uint32 diff) OVERRIDE { //Only if not incombat check if the event is started if (!me->IsInCombat() && instance && instance->GetData(DATA_MAULGAREVENT)) diff --git a/src/server/scripts/Outland/GruulsLair/gruuls_lair.h b/src/server/scripts/Outland/GruulsLair/gruuls_lair.h index 2e9715a7ffe..69ddba8c274 100644 --- a/src/server/scripts/Outland/GruulsLair/gruuls_lair.h +++ b/src/server/scripts/Outland/GruulsLair/gruuls_lair.h @@ -19,16 +19,19 @@ #ifndef DEF_GRUULS_LAIR_H #define DEF_GRUULS_LAIR_H -#define DATA_BLINDEYETHESEER 1 -#define DATA_GRUULEVENT 2 -#define DATA_KIGGLERTHECRAZED 3 -#define DATA_KROSHFIREHAND 4 -#define DATA_MAULGAREVENT 5 -#define DATA_MAULGAREVENT_TANK 6 -#define DATA_OLMTHESUMMONER 7 -#define DATA_MAULGARDOOR 8 -#define DATA_GRUULDOOR 9 -#define DATA_MAULGAR 10 +enum DataTypes +{ + DATA_BLINDEYETHESEER = 1, + DATA_GRUULEVENT = 2, + DATA_KIGGLERTHECRAZED = 3, + DATA_KROSHFIREHAND = 4, + DATA_MAULGAREVENT = 5, + DATA_MAULGAREVENT_TANK = 6, + DATA_OLMTHESUMMONER = 7, + DATA_MAULGARDOOR = 8, + DATA_GRUULDOOR = 9, + DATA_MAULGAR = 10 +}; #define ERROR_INST_DATA "TSCR Error: Instance Data not set properly for Gruul's Lair instance (map 565). Encounters will be buggy." #endif diff --git a/src/server/scripts/Outland/GruulsLair/instance_gruuls_lair.cpp b/src/server/scripts/Outland/GruulsLair/instance_gruuls_lair.cpp index e8aa6838d09..3fbdfe94c05 100644 --- a/src/server/scripts/Outland/GruulsLair/instance_gruuls_lair.cpp +++ b/src/server/scripts/Outland/GruulsLair/instance_gruuls_lair.cpp @@ -39,7 +39,7 @@ class instance_gruuls_lair : public InstanceMapScript public: instance_gruuls_lair() : InstanceMapScript("instance_gruuls_lair", 565) { } - InstanceScript* GetInstanceScript(InstanceMap* map) const + InstanceScript* GetInstanceScript(InstanceMap* map) const OVERRIDE { return new instance_gruuls_lair_InstanceMapScript(map); } @@ -111,13 +111,13 @@ public: } } - void SetData64(uint32 type, uint64 data) + void SetData64(uint32 type, uint64 data) OVERRIDE { if (type == DATA_MAULGAREVENT_TANK) MaulgarEvent_Tank = data; } - uint64 GetData64(uint32 identifier) const + uint64 GetData64(uint32 identifier) const OVERRIDE { switch (identifier) { @@ -133,7 +133,7 @@ public: return 0; } - void SetData(uint32 type, uint32 data) + void SetData(uint32 type, uint32 data) OVERRIDE { switch (type) { @@ -156,7 +156,7 @@ public: SaveToDB(); } - uint32 GetData(uint32 type) const + uint32 GetData(uint32 type) const OVERRIDE { switch (type) { |
