mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-03-15 13:35:08 +00:00
fix(Scripts/Creature): Fel Guard Hound not despawning. (#15300)
This commit is contained in:
@@ -329,7 +329,8 @@ public:
|
|||||||
enum FelGuard
|
enum FelGuard
|
||||||
{
|
{
|
||||||
SPELL_SUMMON_POO = 37688,
|
SPELL_SUMMON_POO = 37688,
|
||||||
NPC_DERANGED_HELBOAR = 16863
|
NPC_DERANGED_HELBOAR = 16863,
|
||||||
|
QUEST_SHIZZ_WORK = 10629,
|
||||||
};
|
};
|
||||||
|
|
||||||
class npc_fel_guard_hound : public CreatureScript
|
class npc_fel_guard_hound : public CreatureScript
|
||||||
@@ -358,7 +359,7 @@ public:
|
|||||||
DoCast(SPELL_SUMMON_POO);
|
DoCast(SPELL_SUMMON_POO);
|
||||||
|
|
||||||
if (Player* owner = me->GetCharmerOrOwnerPlayerOrPlayerItself())
|
if (Player* owner = me->GetCharmerOrOwnerPlayerOrPlayerItself())
|
||||||
me->GetMotionMaster()->MoveFollow(owner, 0.0f, 0.0f);
|
me->GetMotionMaster()->MoveFollow(owner, 1.0f, 90.0f);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -374,6 +375,13 @@ public:
|
|||||||
me->GetMotionMaster()->MovePoint(1, helboar->GetPositionX(), helboar->GetPositionY(), helboar->GetPositionZ());
|
me->GetMotionMaster()->MovePoint(1, helboar->GetPositionX(), helboar->GetPositionY(), helboar->GetPositionZ());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (Player* owner = me->GetCharmerOrOwnerPlayerOrPlayerItself())
|
||||||
|
{
|
||||||
|
if (!owner->HasQuest(QUEST_SHIZZ_WORK))
|
||||||
|
{
|
||||||
|
me->DespawnOrUnsummon();
|
||||||
|
}
|
||||||
|
}
|
||||||
checkTimer = 5000;
|
checkTimer = 5000;
|
||||||
}
|
}
|
||||||
else checkTimer -= diff;
|
else checkTimer -= diff;
|
||||||
|
|||||||
Reference in New Issue
Block a user