Creature/Script: remove obsolete script npc_skywing (#22147)

- replaced with SAI script for the same quest and creature (Skywing)

Ref. https://github.com/TrinityCore/TrinityCore/issues/22078#issuecomment-399760597

(cherry picked from commit 0004531081058a2a4d7a1fbe94545e9328ce7d61)
This commit is contained in:
illfated
2021-10-14 00:09:17 +02:00
committed by Shauren
parent 4cdbcb6ff9
commit 550513ba65
@@ -18,15 +18,13 @@
/* ScriptData
SDName: Terokkar_Forest
SD%Complete: 85
SDComment: Quest support: 9889, 10898, 10052, 10051.
SDComment: Quest support: 9889, 10051, 10052.
SDCategory: Terokkar Forest
EndScriptData */
/* ContentData
npc_unkor_the_ruthless
npc_isla_starmane
npc_skywing
npc_akuno
EndContentData */
#include "ScriptMgr.h"
@@ -161,67 +159,6 @@ public:
};
};
/*######
## npc_skywing
######*/
enum Skywing
{
QUEST_SKYWING = 10898
};
class npc_skywing : public CreatureScript
{
public:
npc_skywing() : CreatureScript("npc_skywing") { }
CreatureAI* GetAI(Creature* creature) const override
{
return new npc_skywingAI(creature);
}
struct npc_skywingAI : public EscortAI
{
public:
npc_skywingAI(Creature* creature) : EscortAI(creature) { }
void WaypointReached(uint32 waypointId, uint32 /*pathId*/) override
{
Player* player = GetPlayerForEscort();
if (!player)
return;
switch (waypointId)
{
case 8:
player->AreaExploredOrEventHappens(QUEST_SKYWING);
break;
}
}
void JustEngagedWith(Unit* /*who*/) override { }
void MoveInLineOfSight(Unit* who) override
{
if (HasEscortState(STATE_ESCORT_ESCORTING))
return;
Player* player = who->ToPlayer();
if (player && player->GetQuestStatus(QUEST_SKYWING) == QUEST_STATUS_INCOMPLETE)
if (me->IsWithinDistInMap(who, 10.0f))
Start(false, false, who->GetGUID());
}
void Reset() override { }
void UpdateAI(uint32 diff) override
{
EscortAI::UpdateAI(diff);
}
};
};
/*######
## npc_isla_starmane
######*/
@@ -322,5 +259,4 @@ void AddSC_terokkar_forest()
{
new npc_unkor_the_ruthless();
new npc_isla_starmane();
new npc_skywing();
}