aboutsummaryrefslogtreecommitdiff
path: root/src/server/scripts/EasternKingdoms
diff options
context:
space:
mode:
authoroffl <offl@users.noreply.github.com>2020-09-12 22:18:32 +0300
committeroffl <offl@users.noreply.github.com>2020-09-12 22:18:32 +0300
commit8c303e4f979cff5c34f228054cea4e81bb70c11c (patch)
tree5cd2e0d5280a24ec3202953b714fd5c4d36853b8 /src/server/scripts/EasternKingdoms
parent090e3da96b101bb29aa0691e5856bd27ff06b0cd (diff)
DB/Quest: Convert & update Homing Robot chickens to SAI
Closes #25239
Diffstat (limited to 'src/server/scripts/EasternKingdoms')
-rw-r--r--src/server/scripts/EasternKingdoms/zone_hinterlands.cpp103
1 files changed, 1 insertions, 102 deletions
diff --git a/src/server/scripts/EasternKingdoms/zone_hinterlands.cpp b/src/server/scripts/EasternKingdoms/zone_hinterlands.cpp
index bfe0851a5af..33fa4724221 100644
--- a/src/server/scripts/EasternKingdoms/zone_hinterlands.cpp
+++ b/src/server/scripts/EasternKingdoms/zone_hinterlands.cpp
@@ -18,12 +18,11 @@
/* ScriptData
SDName: Hinterlands
SD%Complete: 100
-SDComment: Quest support: 863, 2742
+SDComment: Quest support: 2742
SDCategory: The Hinterlands
EndScriptData */
/* ContentData
-npc_oox09hl
npc_rinji
EndContentData */
@@ -34,105 +33,6 @@ EndContentData */
#include "ScriptedEscortAI.h"
/*######
-## npc_oox09hl
-######*/
-
-enum OOX
-{
- SAY_OOX_START = 0,
- SAY_OOX_AGGRO = 1,
- SAY_OOX_AMBUSH = 2,
- SAY_OOX_AMBUSH_REPLY = 3,
- SAY_OOX_END = 4,
- QUEST_RESQUE_OOX_09 = 836,
- NPC_MARAUDING_OWL = 7808,
- NPC_VILE_AMBUSHER = 7809
-};
-
-class npc_oox09hl : public CreatureScript
-{
-public:
- npc_oox09hl() : CreatureScript("npc_oox09hl") { }
-
- struct npc_oox09hlAI : public EscortAI
- {
- npc_oox09hlAI(Creature* creature) : EscortAI(creature) { }
-
- void Reset() override { }
-
- void JustEngagedWith(Unit* who) override
- {
- if (who->GetEntry() == NPC_MARAUDING_OWL || who->GetEntry() == NPC_VILE_AMBUSHER)
- return;
-
- Talk(SAY_OOX_AGGRO);
- }
-
- void JustSummoned(Creature* summoned) override
- {
- summoned->GetMotionMaster()->MovePoint(0, me->GetPositionX(), me->GetPositionY(), me->GetPositionZ());
- }
-
- void OnQuestAccept(Player* player, Quest const* quest) override
- {
- if (quest->GetQuestId() == QUEST_RESQUE_OOX_09)
- {
- me->SetStandState(UNIT_STAND_STATE_STAND);
- me->SetFaction(player->GetTeam() == ALLIANCE ? FACTION_ESCORTEE_A_PASSIVE : FACTION_ESCORTEE_H_PASSIVE);
- Talk(SAY_OOX_START, player);
- EscortAI::Start(false, false, player->GetGUID(), quest);
- }
- }
-
- void WaypointReached(uint32 waypointId, uint32 /*pathId*/) override
- {
- switch (waypointId)
- {
- case 26:
- Talk(SAY_OOX_AMBUSH);
- break;
- case 43:
- Talk(SAY_OOX_AMBUSH);
- break;
- case 64:
- Talk(SAY_OOX_END);
- if (Player* player = GetPlayerForEscort())
- player->GroupEventHappens(QUEST_RESQUE_OOX_09, me);
- break;
- }
- }
-
- void WaypointStarted(uint32 pointId, uint32 /*pathId*/) override
- {
- switch (pointId)
- {
- case 27:
- for (uint8 i = 0; i < 3; ++i)
- {
- const Position src = {147.927444f, -3851.513428f, 130.893f, 0};
- Position dst = me->GetRandomPoint(src, 7.0f);
- DoSummon(NPC_MARAUDING_OWL, dst, 25s, TEMPSUMMON_CORPSE_TIMED_DESPAWN);
- }
- break;
- case 44:
- for (uint8 i = 0; i < 3; ++i)
- {
- const Position src = {-141.151581f, -4291.213867f, 120.130f, 0};
- Position dst = me->GetRandomPoint(src, 7.0f);
- me->SummonCreature(NPC_VILE_AMBUSHER, dst, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 25s);
- }
- break;
- }
- }
- };
-
- CreatureAI* GetAI(Creature* creature) const override
- {
- return new npc_oox09hlAI(creature);
- }
-};
-
-/*######
## npc_rinji
######*/
@@ -324,6 +224,5 @@ public:
void AddSC_hinterlands()
{
- new npc_oox09hl();
new npc_rinji();
}