mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-21 09:44:45 +01:00
Misc: remove incorrectly readded code
This commit is contained in:
@@ -123,109 +123,8 @@ public:
|
||||
|
||||
};
|
||||
|
||||
/*######
|
||||
## go_iruxos
|
||||
## Hand of Iruxos
|
||||
######*/
|
||||
|
||||
enum Iruxos
|
||||
{
|
||||
QUEST_HAND_IRUXOS = 5381,
|
||||
NPC_DEMON_SPIRIT = 11876
|
||||
};
|
||||
|
||||
class go_iruxos : public GameObjectScript
|
||||
{
|
||||
public:
|
||||
go_iruxos() : GameObjectScript("go_iruxos") { }
|
||||
|
||||
bool OnGossipHello(Player* player, GameObject* go) override
|
||||
{
|
||||
if (player->GetQuestStatus(QUEST_HAND_IRUXOS) == QUEST_STATUS_INCOMPLETE && !go->FindNearestCreature(NPC_DEMON_SPIRIT, 25.0f, true))
|
||||
player->SummonCreature(NPC_DEMON_SPIRIT, go->GetPositionX(), go->GetPositionY(), go->GetPositionZ(), 0.0f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 10000);
|
||||
|
||||
return true;
|
||||
}
|
||||
};
|
||||
|
||||
/*######
|
||||
## npc_dalinda_malem. Quest 1440
|
||||
######*/
|
||||
|
||||
enum Dalinda
|
||||
{
|
||||
QUEST_RETURN_TO_VAHLARRIEL = 1440
|
||||
};
|
||||
|
||||
class npc_dalinda : public CreatureScript
|
||||
{
|
||||
public:
|
||||
npc_dalinda() : CreatureScript("npc_dalinda") { }
|
||||
|
||||
struct npc_dalindaAI : public npc_escortAI
|
||||
{
|
||||
npc_dalindaAI(Creature* creature) : npc_escortAI(creature) { }
|
||||
|
||||
void Reset() override { }
|
||||
|
||||
void EnterCombat(Unit* /*who*/) override { }
|
||||
|
||||
void JustDied(Unit* /*killer*/) override
|
||||
{
|
||||
if (Player* player = GetPlayerForEscort())
|
||||
player->FailQuest(QUEST_RETURN_TO_VAHLARRIEL);
|
||||
return;
|
||||
}
|
||||
|
||||
void WaypointReached(uint32 waypointId) override
|
||||
{
|
||||
Player* player = GetPlayerForEscort();
|
||||
|
||||
switch (waypointId)
|
||||
{
|
||||
case 1:
|
||||
me->SetStandState(UNIT_STAND_STATE_STAND);
|
||||
break;
|
||||
case 15:
|
||||
if (player)
|
||||
player->GroupEventHappens(QUEST_RETURN_TO_VAHLARRIEL, me);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void UpdateAI(uint32 diff) override
|
||||
{
|
||||
npc_escortAI::UpdateAI(diff);
|
||||
|
||||
if (!UpdateVictim())
|
||||
return;
|
||||
|
||||
DoMeleeAttackIfReady();
|
||||
}
|
||||
};
|
||||
|
||||
bool OnQuestAccept(Player* player, Creature* creature, Quest const* quest) override
|
||||
{
|
||||
if (quest->GetQuestId() == QUEST_RETURN_TO_VAHLARRIEL)
|
||||
{
|
||||
if (npc_escortAI* escortAI = CAST_AI(npc_dalinda::npc_dalindaAI, creature->AI()))
|
||||
{
|
||||
escortAI->Start(true, false, player->GetGUID());
|
||||
creature->setFaction(113);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
CreatureAI* GetAI(Creature* creature) const override
|
||||
{
|
||||
return new npc_dalindaAI(creature);
|
||||
}
|
||||
};
|
||||
|
||||
void AddSC_desolace()
|
||||
{
|
||||
new npc_aged_dying_ancient_kodo();
|
||||
new go_iruxos();
|
||||
new npc_dalinda();
|
||||
}
|
||||
f
|
||||
Reference in New Issue
Block a user