diff options
author | megamage <none@none> | 2009-05-30 17:17:05 -0500 |
---|---|---|
committer | megamage <none@none> | 2009-05-30 17:17:05 -0500 |
commit | b5778357d9d8c5fb10da5d99c46b48250578cb49 (patch) | |
tree | 118be9301a1d0bc55804ba9626253b4979e66340 | |
parent | 76d0498aae83914b3321039e605e198abe383ac4 (diff) |
*Fix a crash. Thanks to Amok
--HG--
branch : trunk
-rw-r--r-- | src/game/HomeMovementGenerator.cpp | 2 | ||||
-rw-r--r-- | src/game/Object.h | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/src/game/HomeMovementGenerator.cpp b/src/game/HomeMovementGenerator.cpp index a2bad0b0db7..805b4d51a3a 100644 --- a/src/game/HomeMovementGenerator.cpp +++ b/src/game/HomeMovementGenerator.cpp @@ -28,6 +28,8 @@ void HomeMovementGenerator<Creature>::Initialize(Creature & owner) { + float x, y, z; + owner.GetHomePosition(x, y, z, ori); owner.RemoveUnitMovementFlag(MOVEMENTFLAG_WALK_MODE); _setTargetLocation(owner); } diff --git a/src/game/Object.h b/src/game/Object.h index b5ac57b06ca..e6731db1712 100644 --- a/src/game/Object.h +++ b/src/game/Object.h @@ -383,7 +383,6 @@ class TRINITY_DLL_SPEC WorldObject : public Object void Relocate(float x, float y, float z, float orientation) { - assert(orientation > -100 && orientation < 100); m_positionX = x; m_positionY = y; m_positionZ = z; @@ -403,7 +402,7 @@ class TRINITY_DLL_SPEC WorldObject : public Object Relocate(loc.x, loc.y, loc.z, loc.o); } - void SetOrientation(float orientation) { assert(orientation > -100 && orientation < 100); m_orientation = orientation; } + void SetOrientation(float orientation) { m_orientation = orientation; } float GetPositionX( ) const { return m_positionX; } float GetPositionY( ) const { return m_positionY; } |