diff options
author | Keader <keader.android@gmail.com> | 2017-02-04 12:14:28 -0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-02-04 12:14:28 -0300 |
commit | bc95fce93f5f3d0057f6d766567cbd6c341737b8 (patch) | |
tree | bfb62616bda7966f8eaba820f478ed8eaea252d8 /src/server/game/Movement/MotionMaster.cpp | |
parent | ea0393d5cc295fad8ed12e0cf0980c43e727c201 (diff) |
Core/Movement: Added support to change orientation in MovePoint function (#18893)
Diffstat (limited to 'src/server/game/Movement/MotionMaster.cpp')
-rw-r--r-- | src/server/game/Movement/MotionMaster.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/server/game/Movement/MotionMaster.cpp b/src/server/game/Movement/MotionMaster.cpp index ea3583b0cdf..3966c4be9ef 100644 --- a/src/server/game/Movement/MotionMaster.cpp +++ b/src/server/game/Movement/MotionMaster.cpp @@ -321,18 +321,18 @@ void MotionMaster::MoveFleeing(Unit* enemy, uint32 time) } } -void MotionMaster::MovePoint(uint32 id, float x, float y, float z, bool generatePath) +void MotionMaster::MovePoint(uint32 id, float x, float y, float z, float o, bool generatePath) { if (_owner->GetTypeId() == TYPEID_PLAYER) { - TC_LOG_DEBUG("misc", "Player (GUID: %u) targeted point (Id: %u X: %f Y: %f Z: %f).", _owner->GetGUID().GetCounter(), id, x, y, z); - Mutate(new PointMovementGenerator<Player>(id, x, y, z, generatePath), MOTION_SLOT_ACTIVE); + TC_LOG_DEBUG("misc", "Player (GUID: %u) targeted point (Id: %u X: %f Y: %f Z: %f O: %f).", _owner->GetGUID().GetCounter(), id, x, y, z, o); + Mutate(new PointMovementGenerator<Player>(id, x, y, z, o, generatePath), MOTION_SLOT_ACTIVE); } else { - TC_LOG_DEBUG("misc", "Creature (Entry: %u GUID: %u) targeted point (ID: %u X: %f Y: %f Z: %f).", - _owner->GetEntry(), _owner->GetGUID().GetCounter(), id, x, y, z); - Mutate(new PointMovementGenerator<Creature>(id, x, y, z, generatePath), MOTION_SLOT_ACTIVE); + TC_LOG_DEBUG("misc", "Creature (Entry: %u GUID: %u) targeted point (ID: %u X: %f Y: %f Z: %f O: %f).", + _owner->GetEntry(), _owner->GetGUID().GetCounter(), id, x, y, z, o); + Mutate(new PointMovementGenerator<Creature>(id, x, y, z, o, generatePath), MOTION_SLOT_ACTIVE); } } @@ -393,13 +393,13 @@ void MotionMaster::MoveCharge(float x, float y, float z, float speed /*= SPEED_C if (_owner->GetTypeId() == TYPEID_PLAYER) { TC_LOG_DEBUG("misc", "Player (GUID: %u) charged point (X: %f Y: %f Z: %f).", _owner->GetGUID().GetCounter(), x, y, z); - Mutate(new PointMovementGenerator<Player>(id, x, y, z, generatePath, speed), MOTION_SLOT_CONTROLLED); + Mutate(new PointMovementGenerator<Player>(id, x, y, z, 0.0f, generatePath, speed), MOTION_SLOT_CONTROLLED); } else { TC_LOG_DEBUG("misc", "Creature (Entry: %u GUID: %u) charged point (X: %f Y: %f Z: %f).", _owner->GetEntry(), _owner->GetGUID().GetCounter(), x, y, z); - Mutate(new PointMovementGenerator<Creature>(id, x, y, z, generatePath, speed), MOTION_SLOT_CONTROLLED); + Mutate(new PointMovementGenerator<Creature>(id, x, y, z, 0.0f, generatePath, speed), MOTION_SLOT_CONTROLLED); } } |