fix(Core/Quest): Scratches (#2090)

- Correctly despawn NPC Kaliri totem when the quest is completed.
This commit is contained in:
Poszer
2019-07-27 01:49:37 +02:00
committed by GitHub
parent 502d8fc14b
commit 178315f8e2

View File

@@ -425,7 +425,9 @@ enum Daranelle
{
SAY_SPELL_INFLUENCE = 0,
SPELL_LASHHAN_CHANNEL = 36904,
SPELL_DISPELLING_ANALYSIS = 37028
SPELL_DISPELLING_ANALYSIS = 37028,
NPC_KALIRI_TOTEM = 21468
};
class npc_daranelle : public CreatureScript
@@ -448,9 +450,13 @@ public:
{
if (who->HasAura(SPELL_LASHHAN_CHANNEL) && me->IsWithinDistInMap(who, 10.0f))
{
Talk(SAY_SPELL_INFLUENCE, who);
/// @todo Move the below to updateAI and run if this statement == true
DoCast(who, SPELL_DISPELLING_ANALYSIS, true);
if (Creature * bird = who->FindNearestCreature(NPC_KALIRI_TOTEM, 10.0f))
{
Talk(SAY_SPELL_INFLUENCE, who);
/// @todo Move the below to updateAI and run if this statement == true
DoCast(who, SPELL_DISPELLING_ANALYSIS, true);
bird->DespawnOrUnsummon(2000);
}
}
}