Core/MMaps: Revert PATHFIND_INCOMPLETE handling change in ChaseMovementGenerator in 386b5a6fd9 since the current hp reset code in Creature::Update() will reset the hp of bosses as soon as CanNotReachTarget() is true. In case of boss mechanics like Abub'Rekhan at Naxx where the boss throws the player in the air, a PATHFIND_INCOMPLETE path is returned.

The code in Creature::Update() should be modified to wait a few seconds before resetting the hp. PATHFIND_NOPATH / PATHFIND_INCOMPLETE don't really mean that the Creature can't attack the player anyway either.
This commit is contained in:
jackpoz
2019-04-28 14:50:33 +02:00
parent e3a9a9bfb2
commit d910ffd779

View File

@@ -185,7 +185,7 @@ bool ChaseMovementGenerator::Update(Unit* owner, uint32 diff)
owner->UpdateAllowedPositionZ(x, y, z);
bool success = _path->CalculatePath(x, y, z, owner->CanFly());
if (!success || (_path->GetPathType() & (PATHFIND_NOPATH | PATHFIND_INCOMPLETE)))
if (!success || (_path->GetPathType() & (PATHFIND_NOPATH /* | PATHFIND_INCOMPLETE*/)))
{
if (cOwner)
cOwner->SetCannotReachTarget(true);