diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/server/scripts/Outland/CMakeLists.txt | 2 | ||||
-rw-r--r-- | src/server/scripts/Outland/TempestKeep/botanica/boss_commander_sarannis.cpp | 24 | ||||
-rw-r--r-- | src/server/scripts/Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp | 3 | ||||
-rw-r--r-- | src/server/scripts/Outland/TempestKeep/botanica/boss_laj.cpp | 3 | ||||
-rw-r--r-- | src/server/scripts/Outland/TempestKeep/botanica/boss_warp_splinter.cpp | 5 | ||||
-rw-r--r-- | src/server/scripts/Outland/TempestKeep/botanica/instance_the_botanica.cpp (renamed from src/server/scripts/Outland/TempestKeep/botanica/the_botanica.cpp) | 0 | ||||
-rw-r--r-- | src/server/scripts/Outland/TempestKeep/botanica/thorngrin_the_tender.cpp | 22 |
7 files changed, 33 insertions, 26 deletions
diff --git a/src/server/scripts/Outland/CMakeLists.txt b/src/server/scripts/Outland/CMakeLists.txt index 05f329b5b1a..173af3374ad 100644 --- a/src/server/scripts/Outland/CMakeLists.txt +++ b/src/server/scripts/Outland/CMakeLists.txt @@ -60,7 +60,7 @@ set(scripts_STAT_SRCS Outland/TempestKeep/Eye/boss_kaelthas.cpp Outland/TempestKeep/Eye/the_eye.cpp Outland/TempestKeep/botanica/the_botanica.h - Outland/TempestKeep/botanica/the_botanica.cpp + Outland/TempestKeep/botanica/instance_the_botanica.cpp Outland/TempestKeep/botanica/boss_commander_sarannis.cpp Outland/TempestKeep/botanica/thorngrin_the_tender.cpp Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp diff --git a/src/server/scripts/Outland/TempestKeep/botanica/boss_commander_sarannis.cpp b/src/server/scripts/Outland/TempestKeep/botanica/boss_commander_sarannis.cpp index a28e0f0cd71..f64276940aa 100644 --- a/src/server/scripts/Outland/TempestKeep/botanica/boss_commander_sarannis.cpp +++ b/src/server/scripts/Outland/TempestKeep/botanica/boss_commander_sarannis.cpp @@ -17,6 +17,7 @@ #include "ScriptMgr.h" #include "ScriptedCreature.h" +#include "the_botanica.h" enum Says { @@ -46,21 +47,22 @@ class boss_commander_sarannis : public CreatureScript { public: boss_commander_sarannis() : CreatureScript("boss_commander_sarannis") { } - struct boss_commander_sarannisAI : public ScriptedAI + struct boss_commander_sarannisAI : public BossAI { boss_commander_sarannisAI(Creature* creature) : BossAI(creature, DATA_COMMANDER_SARANNIS) { } void Reset() { + _Reset(); _phase = true; } void EnterCombat(Unit* /*who*/) { + _EnterCombat(); Talk(SAY_AGGRO); - _events.Reset(); - _events.ScheduleEvent(EVENT_ARCANE_RESONANCE, 42700); - _events.ScheduleEvent(EVENT_ARCANE_DEVASTATION, 15200); + events.ScheduleEvent(EVENT_ARCANE_RESONANCE, 42700); + events.ScheduleEvent(EVENT_ARCANE_DEVASTATION, 15200); } void KilledUnit(Unit* /*victim*/) @@ -70,6 +72,7 @@ class boss_commander_sarannis : public CreatureScript void JustDied(Unit* /*killer*/) { + _JustDied(); Talk(SAY_DEATH); } @@ -86,32 +89,32 @@ class boss_commander_sarannis : public CreatureScript void JustSummoned(Creature* summon) { - ScriptedAI::JustSummoned(summon); + BossAI::JustSummoned(summon); } - void UpdateAI(const uint32 diff) + void UpdateAI(uint32 const diff) { if (!UpdateVictim()) return; - _events.Update(diff); + events.Update(diff); if (me->HasUnitState(UNIT_STATE_CASTING)) return; - while (uint32 eventId = _events.ExecuteEvent()) + while (uint32 eventId = events.ExecuteEvent()) { switch (eventId) { case EVENT_ARCANE_RESONANCE: Talk(SAY_ARCANE_RESONANCE); DoCastVictim(SPELL_ARCANE_RESONANCE, true); - _events.ScheduleEvent(EVENT_ARCANE_RESONANCE, 42700); + events.ScheduleEvent(EVENT_ARCANE_RESONANCE, 42700); break; case EVENT_ARCANE_DEVASTATION: Talk(SAY_ARCANE_DEVASTATION); DoCastVictim(SPELL_ARCANE_DEVASTATION, true); - _events.ScheduleEvent(EVENT_ARCANE_DEVASTATION, urand(11000, 19200)); + events.ScheduleEvent(EVENT_ARCANE_DEVASTATION, urand(11000, 19200)); break; default: break; @@ -122,7 +125,6 @@ class boss_commander_sarannis : public CreatureScript } private: - EventMap _events; bool _phase; }; diff --git a/src/server/scripts/Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp b/src/server/scripts/Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp index 12e5acf4222..2ab527c2fd5 100644 --- a/src/server/scripts/Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp +++ b/src/server/scripts/Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp @@ -25,6 +25,7 @@ EndScriptData */ #include "ScriptMgr.h" #include "ScriptedCreature.h" +#include "the_botanica.h" enum eSays { @@ -58,7 +59,7 @@ class boss_high_botanist_freywinn : public CreatureScript { } - struct boss_high_botanist_freywinnAI : public ScriptedAI + struct boss_high_botanist_freywinnAI : public BossAI { boss_high_botanist_freywinnAI(Creature* creature) : BossAI(creature, DATA_HIGH_BOTANIST_FREYWINN) { } diff --git a/src/server/scripts/Outland/TempestKeep/botanica/boss_laj.cpp b/src/server/scripts/Outland/TempestKeep/botanica/boss_laj.cpp index 58f5d7ade54..bd9195e44f8 100644 --- a/src/server/scripts/Outland/TempestKeep/botanica/boss_laj.cpp +++ b/src/server/scripts/Outland/TempestKeep/botanica/boss_laj.cpp @@ -25,6 +25,7 @@ EndScriptData */ #include "ScriptMgr.h" #include "ScriptedCreature.h" +#include "the_botanica.h" enum eSpells { @@ -59,7 +60,7 @@ class boss_laj : public CreatureScript { } - struct boss_lajAI : public ScriptedAI + struct boss_lajAI : public BossAI { boss_lajAI(Creature* creature) : BossAI(creature, DATA_LAJ) { } diff --git a/src/server/scripts/Outland/TempestKeep/botanica/boss_warp_splinter.cpp b/src/server/scripts/Outland/TempestKeep/botanica/boss_warp_splinter.cpp index 131c0fcaf75..d2b6c44ec7b 100644 --- a/src/server/scripts/Outland/TempestKeep/botanica/boss_warp_splinter.cpp +++ b/src/server/scripts/Outland/TempestKeep/botanica/boss_warp_splinter.cpp @@ -25,6 +25,7 @@ EndScriptData */ #include "ScriptMgr.h" #include "ScriptedCreature.h" +#include "the_botanica.h" enum eSays { @@ -134,9 +135,9 @@ class boss_warp_splinter : public CreatureScript : CreatureScript("boss_warp_splinter") { } - struct boss_warp_splinterAI : public ScriptedAI + struct boss_warp_splinterAI : public BossAI { - boss_warp_splinterAI(Creature* creature) : BossAI(creature, DATA_WARP_SPLINTER) { } + boss_warp_splinterAI(Creature* creature) : BossAI(creature, DATA_WARP_SPLINTER) { Treant_Spawn_Pos_X = creature->GetPositionX(); Treant_Spawn_Pos_Y = creature->GetPositionY(); diff --git a/src/server/scripts/Outland/TempestKeep/botanica/the_botanica.cpp b/src/server/scripts/Outland/TempestKeep/botanica/instance_the_botanica.cpp index 69b95e8c813..69b95e8c813 100644 --- a/src/server/scripts/Outland/TempestKeep/botanica/the_botanica.cpp +++ b/src/server/scripts/Outland/TempestKeep/botanica/instance_the_botanica.cpp diff --git a/src/server/scripts/Outland/TempestKeep/botanica/thorngrin_the_tender.cpp b/src/server/scripts/Outland/TempestKeep/botanica/thorngrin_the_tender.cpp index abc0552f08c..ffd48f4dcb5 100644 --- a/src/server/scripts/Outland/TempestKeep/botanica/thorngrin_the_tender.cpp +++ b/src/server/scripts/Outland/TempestKeep/botanica/thorngrin_the_tender.cpp @@ -17,6 +17,7 @@ #include "ScriptMgr.h" #include "ScriptedCreature.h" +#include "the_botanica.h" enum Says { @@ -55,17 +56,18 @@ class boss_thorngrin_the_tender : public CreatureScript void Reset() { + _Reset(); _phase1 = true; _phase2 = true; } void EnterCombat(Unit* /*who*/) { + _EnterCombat(); Talk(SAY_AGGRO); - _events.Reset(); - _events.ScheduleEvent(EVENT_SACRIFICE, 5700); - _events.ScheduleEvent(EVENT_HELLFIRE, IsHeroic() ? urand(17400, 19300) : 18000); - _events.ScheduleEvent(EVENT_ENRAGE, 12000); + events.ScheduleEvent(EVENT_SACRIFICE, 5700); + events.ScheduleEvent(EVENT_HELLFIRE, IsHeroic() ? urand(17400, 19300) : 18000); + events.ScheduleEvent(EVENT_ENRAGE, 12000); } void KilledUnit(Unit* /*victim*/) @@ -75,6 +77,7 @@ class boss_thorngrin_the_tender : public CreatureScript void JustDied(Unit* /*killer*/) { + _JustDied(); Talk(SAY_DEATH); } @@ -97,12 +100,12 @@ class boss_thorngrin_the_tender : public CreatureScript if (!UpdateVictim()) return; - _events.Update(diff); + events.Update(diff); if (me->HasUnitState(UNIT_STATE_CASTING)) return; - while (uint32 eventId = _events.ExecuteEvent()) + while (uint32 eventId = events.ExecuteEvent()) { switch (eventId) { @@ -112,17 +115,17 @@ class boss_thorngrin_the_tender : public CreatureScript Talk(SAY_CAST_SACRIFICE); DoCast(target, SPELL_SACRIFICE, true); } - _events.ScheduleEvent(EVENT_SACRIFICE, 29400); + events.ScheduleEvent(EVENT_SACRIFICE, 29400); break; case EVENT_HELLFIRE: Talk(SAY_CAST_HELLFIRE); DoCastVictim(DUNGEON_MODE(SPELL_HELLFIRE_NORMAL, SPELL_HELLFIRE_HEROIC), true); - _events.ScheduleEvent(EVENT_HELLFIRE, IsHeroic() ? urand(17400, 19300) : 18000); + events.ScheduleEvent(EVENT_HELLFIRE, IsHeroic() ? urand(17400, 19300) : 18000); break; case EVENT_ENRAGE: Talk(EMOTE_ENRAGE); DoCast(me, SPELL_ENRAGE); - _events.ScheduleEvent(EVENT_ENRAGE, 33000); + events.ScheduleEvent(EVENT_ENRAGE, 33000); break; default: break; @@ -133,7 +136,6 @@ class boss_thorngrin_the_tender : public CreatureScript } private: - EventMap _events; bool _phase1; bool _phase2; }; |