summaryrefslogtreecommitdiffstats
path: root/src/control/CarCtrl.h
diff options
context:
space:
mode:
authoraap <aap@papnet.eu>2019-09-12 10:06:30 +0200
committerGitHub <noreply@github.com>2019-09-12 10:06:30 +0200
commit7f81eb86a34ed62e4a6990dc88bb150de9dfeab7 (patch)
treec7f10e695c67553279edca79815cd60895a94366 /src/control/CarCtrl.h
parentMerge pull request #202 from erorcun/erorcun (diff)
parentmake ATTEMPTS_TO_FIND_NEXT_NODE a define (diff)
downloadre3-7f81eb86a34ed62e4a6990dc88bb150de9dfeab7.tar
re3-7f81eb86a34ed62e4a6990dc88bb150de9dfeab7.tar.gz
re3-7f81eb86a34ed62e4a6990dc88bb150de9dfeab7.tar.bz2
re3-7f81eb86a34ed62e4a6990dc88bb150de9dfeab7.tar.lz
re3-7f81eb86a34ed62e4a6990dc88bb150de9dfeab7.tar.xz
re3-7f81eb86a34ed62e4a6990dc88bb150de9dfeab7.tar.zst
re3-7f81eb86a34ed62e4a6990dc88bb150de9dfeab7.zip
Diffstat (limited to 'src/control/CarCtrl.h')
-rw-r--r--src/control/CarCtrl.h14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/control/CarCtrl.h b/src/control/CarCtrl.h
index 77982ba6..b06c1ca2 100644
--- a/src/control/CarCtrl.h
+++ b/src/control/CarCtrl.h
@@ -11,6 +11,10 @@ enum{
#define LANE_WIDTH 5.0f
+#ifdef FIX_BUGS
+#define FIX_PATHFIND_BUG
+#endif
+
class CCarCtrl
{
enum eCarClass {
@@ -56,7 +60,7 @@ public:
static bool IsThisVehicleInteresting(CVehicle*);
static int32 CountCarsOfType(int32 mi);
static void SlowCarOnRailsDownForTrafficAndLights(CVehicle*);
- static void PickNextNodeAccordingStrategy(CVehicle*);
+ static bool PickNextNodeAccordingStrategy(CVehicle*);
static void DragCarToPoint(CVehicle*, CVector*);
static float FindMaximumSpeedForThisCarInTraffic(CVehicle*);
static void SlowCarDownForCarsSectorList(CPtrList&, CVehicle*, float, float, float, float, float*, float);
@@ -71,6 +75,14 @@ public:
static void WeaveForPed(CEntity*, CVehicle*, float*, float*);
static void WeaveThroughObjectsSectorList(CPtrList&, CVehicle*, float, float, float, float, float*, float*);
static void WeaveForObject(CEntity*, CVehicle*, float*, float*);
+#ifdef FIX_PATHFIND_BUG
+ static void PickNextNodeToChaseCar(CVehicle*, float, float, float, CVehicle*);
+#else
+ static void PickNextNodeToChaseCar(CVehicle*, float, float, CVehicle*);
+#endif
+ static bool PickNextNodeToFollowPath(CVehicle*);
+ static void PickNextNodeRandomly(CVehicle*);
+ static uint8 FindPathDirection(int32, int32, int32);
static float GetOffsetOfLaneFromCenterOfRoad(int8 lane, CCarPathLink* pLink)
{