diff options
Diffstat (limited to 'src/control/CarCtrl.cpp')
-rw-r--r-- | src/control/CarCtrl.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/control/CarCtrl.cpp b/src/control/CarCtrl.cpp index 781c8799..19f2c628 100644 --- a/src/control/CarCtrl.cpp +++ b/src/control/CarCtrl.cpp @@ -2120,8 +2120,9 @@ bool CCarCtrl::PickNextNodeToFollowPath(CVehicle* pVehicle) pVehicle->AutoPilot.m_vecDestinationCoors, pVehicle->AutoPilot.m_aPathFindNodesInfo, &pVehicle->AutoPilot.m_nPathFindNodesCount, NUM_PATH_NODES_IN_AUTOPILOT, pVehicle, nil, 999999.9f, -1); - if (pVehicle->AutoPilot.m_nPathFindNodesCount < 1) + if (pVehicle->AutoPilot.m_nPathFindNodesCount < 2) return true; + pVehicle->AutoPilot.RemoveOnePathNode(); } CPathNode* pNextPathNode = &ThePaths.m_pathNodes[pVehicle->AutoPilot.m_nNextRouteNode]; CCarPathLink* pCurLink = &ThePaths.m_carPathLinks[pVehicle->AutoPilot.m_nNextPathNodeInfo]; |