Core/Movement: attempt to fix Linux build

This commit is contained in:
Ovahlord
2019-01-12 18:31:02 +01:00
parent 77e5ab6ce0
commit f8a7ea4722

View File

@@ -106,7 +106,8 @@ bool TargetedMovementGenerator<T, D>::DoUpdate(T* owner, uint32 diff)
// the owner needs to reposition itself when being too close to its victim
if (Creature* me = owner->ToCreature())
{
if (GetMovementGeneratorType() == CHASE_MOTION_TYPE && me->IsAllowedToRepostionAgainst(GetTarget()))
MovementGeneratorType type = GetMovementGeneratorType();
if (type == CHASE_MOTION_TYPE && me->IsAllowedToRepostionAgainst(GetTarget()))
{
if (me->GetCombatReach() > me->GetPosition().GetExactDist(GetTarget()->GetPosition()))
{