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
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -589,9 +589,7 @@ 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()));
}
}
}
}
@ -600,10 +598,8 @@ public:
{
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();
}
}
}
}