diff options
author | ZenoX92 <ZenoX92@users.noreply.github.com> | 2018-08-22 18:07:33 +0200 |
---|---|---|
committer | Shauren <shauren.trinity@gmail.com> | 2021-10-22 21:50:04 +0200 |
commit | eb241db1873db339d943e2846f9b1de5344e76c4 (patch) | |
tree | da14ccb65643bb9a834e738f69c5cd063bf44b7b /src | |
parent | 82d5b7c744f6316ea6c66682ad9f5dd37fb4d2f3 (diff) |
DB/Quest: Move the Sunken Treasure to SAI
Closes #22290
(cherry picked from commit 42fec4a698d0a4b51277d5ad3f484e195eda1d5d)
Diffstat (limited to 'src')
-rw-r--r-- | src/server/scripts/EasternKingdoms/eastern_kingdoms_script_loader.cpp | 4 | ||||
-rw-r--r-- | src/server/scripts/EasternKingdoms/zone_arathi_highlands.cpp | 160 |
2 files changed, 2 insertions, 162 deletions
diff --git a/src/server/scripts/EasternKingdoms/eastern_kingdoms_script_loader.cpp b/src/server/scripts/EasternKingdoms/eastern_kingdoms_script_loader.cpp index a6d1d6a08c6..cc12b34da46 100644 --- a/src/server/scripts/EasternKingdoms/eastern_kingdoms_script_loader.cpp +++ b/src/server/scripts/EasternKingdoms/eastern_kingdoms_script_loader.cpp @@ -183,7 +183,7 @@ void AddSC_boss_wushoolay(); void AddSC_boss_zanzil(); void AddSC_instance_zulgurub(); //void AddSC_alterac_mountains(); -void AddSC_arathi_highlands(); +//void AddSC_arathi_highlands(); void AddSC_blasted_lands(); void AddSC_burning_steppes(); void AddSC_dun_morogh(); @@ -374,7 +374,7 @@ void AddEasternKingdomsScripts() AddSC_instance_zulgurub(); //AddSC_alterac_mountains(); - AddSC_arathi_highlands(); + //AddSC_arathi_highlands(); AddSC_blasted_lands(); AddSC_burning_steppes(); AddSC_dun_morogh(); diff --git a/src/server/scripts/EasternKingdoms/zone_arathi_highlands.cpp b/src/server/scripts/EasternKingdoms/zone_arathi_highlands.cpp deleted file mode 100644 index 66b80f22b4d..00000000000 --- a/src/server/scripts/EasternKingdoms/zone_arathi_highlands.cpp +++ /dev/null @@ -1,160 +0,0 @@ -/* - * This file is part of the TrinityCore Project. See AUTHORS file for Copyright information - * - * This program is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License as published by the - * Free Software Foundation; either version 2 of the License, or (at your - * option) any later version. - * - * This program is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for - * more details. - * - * You should have received a copy of the GNU General Public License along - * with this program. If not, see <http://www.gnu.org/licenses/>. - */ - -/* ScriptData -SDName: Arathi Highlands -SD%Complete: 100 -SDComment: Quest support: 665 -SDCategory: Arathi Highlands -EndScriptData */ - -/* ContentData -npc_professor_phizzlethorpe -EndContentData */ - -#include "ScriptMgr.h" -#include "ScriptedCreature.h" -#include "ScriptedEscortAI.h" -#include "Player.h" - -/*###### -## npc_professor_phizzlethorpe -######*/ - -enum ProfessorPhizzlethorpe -{ - // Yells - SAY_PROGRESS_1 = 0, - SAY_PROGRESS_2 = 1, - SAY_PROGRESS_3 = 2, - EMOTE_PROGRESS_4 = 3, - SAY_AGGRO = 4, - SAY_PROGRESS_5 = 5, - SAY_PROGRESS_6 = 6, - SAY_PROGRESS_7 = 7, - EMOTE_PROGRESS_8 = 8, - SAY_PROGRESS_9 = 9, - EVENT_SAY_3 = 1, - EVENT_SAY_6 = 2, - EVENT_SAY_8 = 3, - - // Quests - QUEST_SUNKEN_TREASURE = 665, - QUEST_GOGGLE_BOGGLE = 26050, - // Creatures - NPC_VENGEFUL_SURGE = 2776 -}; - -class npc_professor_phizzlethorpe : public CreatureScript -{ - public: - npc_professor_phizzlethorpe() : CreatureScript("npc_professor_phizzlethorpe") { } - - struct npc_professor_phizzlethorpeAI : public EscortAI - { - npc_professor_phizzlethorpeAI(Creature* creature) : EscortAI(creature) { } - - void WaypointReached(uint32 waypointId, uint32 /*pathId*/) override - { - Player* player = GetPlayerForEscort(); - if (!player) - return; - - switch (waypointId) - { - case 6: - Talk(SAY_PROGRESS_2, player); - events.ScheduleEvent(EVENT_SAY_3, 3000); - break; - case 8: - Talk(EMOTE_PROGRESS_4); - me->SummonCreature(NPC_VENGEFUL_SURGE, -2065.505f, -2136.88f, 22.20362f, 1.0f, TEMPSUMMON_CORPSE_DESPAWN, 0); - me->SummonCreature(NPC_VENGEFUL_SURGE, -2059.249f, -2134.88f, 21.51582f, 1.0f, TEMPSUMMON_CORPSE_DESPAWN, 0); - break; - case 11: - Talk(SAY_PROGRESS_5, player); - events.ScheduleEvent(EVENT_SAY_6, 11000); - break; - case 17: - Talk(SAY_PROGRESS_7, player); - events.ScheduleEvent(EVENT_SAY_8, 6000); - break; - } - } - - void JustSummoned(Creature* summoned) override - { - summoned->AI()->AttackStart(me); - } - - void JustEngagedWith(Unit* /*who*/) override - { - Talk(SAY_AGGRO); - } - - void QuestAccept(Player* player, Quest const* quest) override - { - if (quest->GetQuestId() == QUEST_SUNKEN_TREASURE) - { - Talk(SAY_PROGRESS_1, player); - EscortAI::Start(false, false, player->GetGUID(), quest); - me->SetFaction(FACTION_ESCORTEE_N_NEUTRAL_PASSIVE); - } - } - - void UpdateAI(uint32 diff) override - { - Player* player = GetPlayerForEscort(); - if (!player) - return; - - events.Update(diff); - - while (uint32 event = events.ExecuteEvent()) - { - switch (event) - { - case EVENT_SAY_3: - Talk(SAY_PROGRESS_3, player); - break; - case EVENT_SAY_6: - Talk(SAY_PROGRESS_6, player); - SetRun(); - break; - case EVENT_SAY_8: - Talk(EMOTE_PROGRESS_8); - Talk(SAY_PROGRESS_9, player); - player->GroupEventHappens(QUEST_GOGGLE_BOGGLE, me); - break; - } - } - EscortAI::UpdateAI(diff); - } - - EventMap events; - }; - - CreatureAI* GetAI(Creature* creature) const override - { - return new npc_professor_phizzlethorpeAI(creature); - } -}; - -void AddSC_arathi_highlands() -{ - new npc_professor_phizzlethorpe(); -} |