Movement bug fix. Npc mistakenly move away from its new target.
This commit is contained in:
1 parent
d1e3be8b00
commit
a2337bff45
1 file changed
+3
@@ -48,6 +48,9 @@ void TargetedMovementGeneratorMedium<T, D>::_setTargetLocation(T* owner, bool up
|
||||
{
|
||||
if (!i_offset)
|
||||
{
|
||||
if (i_target->IsWithinDistInMap(owner, CONTACT_DISTANCE))
|
||||
return;
|
||||
|
||||
// to nearest contact position
|
||||
i_target->GetContactPoint(owner, x, y, z);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user