mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-21 09:44:45 +01:00
*Fix build in Linux.
--HG-- branch : trunk
This commit is contained in:
@@ -31,24 +31,6 @@ template<class T>
|
||||
void
|
||||
WaypointMovementGenerator<T>::Initialize(T &u){}
|
||||
|
||||
template<>
|
||||
void
|
||||
WaypointMovementGenerator<Creature>::Initialize(Creature &u)
|
||||
{
|
||||
u.StopMoving();
|
||||
if(!path_id)
|
||||
path_id = u.GetWaypointPath();
|
||||
waypoints = WaypointMgr.GetPath(path_id);
|
||||
if(waypoints && waypoints->size())
|
||||
{
|
||||
Traveller<Creature> traveller(u);
|
||||
node = *(waypoints->at(i_currentNode));
|
||||
InitTraveller(u,node);
|
||||
i_destinationHolder.SetDestination(traveller, node.x, node.y, node.z);
|
||||
i_nextMoveTime.Reset(i_destinationHolder.GetTotalTravelTime());
|
||||
}
|
||||
}
|
||||
|
||||
template<>
|
||||
void
|
||||
WaypointMovementGenerator<Creature>::Finalize(Creature &u){}
|
||||
@@ -108,6 +90,24 @@ void WaypointMovementGenerator<Creature>::InitTraveller(Creature &unit, const Wa
|
||||
unit.addUnitState(UNIT_STAT_ROAMING);
|
||||
}
|
||||
|
||||
template<>
|
||||
void
|
||||
WaypointMovementGenerator<Creature>::Initialize(Creature &u)
|
||||
{
|
||||
u.StopMoving();
|
||||
if(!path_id)
|
||||
path_id = u.GetWaypointPath();
|
||||
waypoints = WaypointMgr.GetPath(path_id);
|
||||
if(waypoints && waypoints->size())
|
||||
{
|
||||
Traveller<Creature> traveller(u);
|
||||
node = *(waypoints->at(i_currentNode));
|
||||
InitTraveller(u,node);
|
||||
i_destinationHolder.SetDestination(traveller, node.x, node.y, node.z);
|
||||
i_nextMoveTime.Reset(i_destinationHolder.GetTotalTravelTime());
|
||||
}
|
||||
}
|
||||
|
||||
template<>
|
||||
void WaypointMovementGenerator<Player>::InitTraveller(Player &unit, const WaypointData &node){}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user