fix(Scripts/HellfirePeninsula): Another null check (#25497)

This commit is contained in:
Andrew
2026-04-18 07:52:09 -03:00
committed by GitHub
parent 1831e2a5a9
commit 7787407477

View File

@@ -589,24 +589,20 @@ public:
for (Creature* whelp : creatureList)
{
if (whelp && whelp->IsAlive() && !whelp->IsInCombat() && whelp->GetMotionMaster()->GetCurrentMovementGeneratorType() != HOME_MOTION_TYPE)
{
whelp->GetMotionMaster()->MovePoint(0, me->GetNearPosition(4.0f, whelp->GetOrientation()));
}
}
}
}
else if (state == GO_JUST_DEACTIVATED)
{
{
for (Creature* whelp : creatureList)
{
if (whelp->IsAlive() && !whelp->IsInCombat() && whelp->GetMotionMaster()->GetCurrentMovementGeneratorType() != HOME_MOTION_TYPE)
{
if (whelp && whelp->IsAlive() && !whelp->IsInCombat() && whelp->GetMotionMaster()->GetCurrentMovementGeneratorType() != HOME_MOTION_TYPE)
whelp->GetMotionMaster()->MoveTargetedHome();
}
}
}
}
else
{
creatureList.clear();