From 76667e45a902f86bd341d40efa28037137e5e541 Mon Sep 17 00:00:00 2001 From: ccrs Date: Sat, 5 May 2018 18:53:59 +0200 Subject: Core/Movement: crashfix workaround untested ref #18471 --- src/server/game/Entities/Unit/Unit.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index 2f8f2b26726..7c78ca3f649 100644 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -13040,7 +13040,9 @@ void Unit::SetFacingTo(float ori, bool force) if (HasUnitMovementFlag(MOVEMENTFLAG_ONTRANSPORT) && GetTransGUID()) init.DisableTransportPathTransformations(); // It makes no sense to target global orientation init.SetFacing(ori); - GetMotionMaster()->LaunchMoveSpline(std::move(init), EVENT_FACE, MOTION_SLOT_CONTROLLED); + + //GetMotionMaster()->LaunchMoveSpline(std::move(init), EVENT_FACE, MOTION_SLOT_CONTROLLED); + init.Launch(); } void Unit::SetFacingToObject(WorldObject const* object, bool force) @@ -13053,7 +13055,9 @@ void Unit::SetFacingToObject(WorldObject const* object, bool force) Movement::MoveSplineInit init(this); init.MoveTo(GetPositionX(), GetPositionY(), GetPositionZ(), false); init.SetFacing(GetAbsoluteAngle(object)); // when on transport, GetAbsoluteAngle will still return global coordinates (and angle) that needs transforming - GetMotionMaster()->LaunchMoveSpline(std::move(init), EVENT_FACE, MOTION_SLOT_CONTROLLED); + + //GetMotionMaster()->LaunchMoveSpline(std::move(init), EVENT_FACE, MOTION_SLOT_CONTROLLED); + init.Launch(); } bool Unit::SetWalk(bool enable) -- cgit v1.2.3