diff options
author | offl <offl@users.noreply.github.com> | 2020-05-19 23:06:05 +0200 |
---|---|---|
committer | Killyana <morphone1@gmail.com> | 2020-05-19 23:06:05 +0200 |
commit | cc5bea023a0c43f1c58e2cd93267d9e339659442 (patch) | |
tree | f3ee707a3580850f870d0202ddf40a57894f35e6 /src | |
parent | 97319c7c19944fa4b5e461273ff7e8c389959c46 (diff) |
DB/Quest: Convert & update support for 'Hypercapacitor Gizmo' to SAI
Closes #24640
Diffstat (limited to 'src')
-rw-r--r-- | src/server/scripts/Kalimdor/zone_thousand_needles.cpp | 73 |
1 files changed, 0 insertions, 73 deletions
diff --git a/src/server/scripts/Kalimdor/zone_thousand_needles.cpp b/src/server/scripts/Kalimdor/zone_thousand_needles.cpp index 6e677153374..8a69dec95e5 100644 --- a/src/server/scripts/Kalimdor/zone_thousand_needles.cpp +++ b/src/server/scripts/Kalimdor/zone_thousand_needles.cpp @@ -25,8 +25,6 @@ EndScriptData */ /* ContentData npc_lakota_windsong npc_swiftmountain -npc_enraged_panther -go_panther_cage EndContentData */ #include "ScriptMgr.h" @@ -199,79 +197,8 @@ public: } }; -enum PantherCage -{ - QUEST_HYPERCAPACITOR_GIZMO = 5151, - ENRAGED_PANTHER = 10992 -}; - -class go_panther_cage : public GameObjectScript -{ -public: - go_panther_cage() : GameObjectScript("go_panther_cage") { } - - struct go_panther_cageAI : public GameObjectAI - { - go_panther_cageAI(GameObject* go) : GameObjectAI(go) { } - - bool GossipHello(Player* player) override - { - me->UseDoorOrButton(); - if (player->GetQuestStatus(QUEST_HYPERCAPACITOR_GIZMO) == QUEST_STATUS_INCOMPLETE) - { - if (Creature* panther = me->FindNearestCreature(ENRAGED_PANTHER, 5, true)) - { - panther->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE); - panther->SetReactState(REACT_AGGRESSIVE); - panther->AI()->AttackStart(player); - } - } - - return true; - } - }; - - GameObjectAI* GetAI(GameObject* go) const override - { - return new go_panther_cageAI(go); - } -}; - -class npc_enraged_panther : public CreatureScript -{ -public: - npc_enraged_panther() : CreatureScript("npc_enraged_panther") { } - - CreatureAI* GetAI(Creature* creature) const override - { - return new npc_enraged_pantherAI(creature); - } - - struct npc_enraged_pantherAI : public ScriptedAI - { - npc_enraged_pantherAI(Creature* creature) : ScriptedAI(creature) { } - - void Reset() override - { - me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE); - me->SetReactState(REACT_PASSIVE); - } - - void UpdateAI(uint32 /*diff*/) override - { - if (!UpdateVictim()) - return; - - DoMeleeAttackIfReady(); - } - }; - -}; - void AddSC_thousand_needles() { new npc_lakota_windsong(); new npc_paoka_swiftmountain(); - new npc_enraged_panther(); - new go_panther_cage(); } |