summaryrefslogtreecommitdiffstats
path: root/src/control
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/control/CarCtrl.cpp8
-rw-r--r--src/control/CarCtrl.h1
-rw-r--r--src/control/Replay.cpp2
3 files changed, 10 insertions, 1 deletions
diff --git a/src/control/CarCtrl.cpp b/src/control/CarCtrl.cpp
index 7acfa64a..edf4d1ae 100644
--- a/src/control/CarCtrl.cpp
+++ b/src/control/CarCtrl.cpp
@@ -16,3 +16,11 @@ WRAPPER bool CCarCtrl::JoinCarWithRoadSystemGotoCoors(CVehicle*, CVector, bool)
WRAPPER void CCarCtrl::JoinCarWithRoadSystem(CVehicle*) { EAXJMP(0x41F820); }
WRAPPER void CCarCtrl::SteerAICarWithPhysics(CVehicle*) { EAXJMP(0x41DA60); }
WRAPPER void CCarCtrl::UpdateCarOnRails(CVehicle*) { EAXJMP(0x418880); }
+
+bool
+CCarCtrl::MapCouldMoveInThisArea(float x, float y)
+{
+ // bridge moves up and down
+ return x > -342.0f && x < -219.0f &&
+ y > -677.0f && y < -580.0f;
+}
diff --git a/src/control/CarCtrl.h b/src/control/CarCtrl.h
index a15279d3..7e3f70a9 100644
--- a/src/control/CarCtrl.h
+++ b/src/control/CarCtrl.h
@@ -13,6 +13,7 @@ public:
static void JoinCarWithRoadSystem(CVehicle*);
static void SteerAICarWithPhysics(CVehicle*);
static void UpdateCarOnRails(CVehicle*);
+ static bool MapCouldMoveInThisArea(float x, float y);
static int32 &NumLawEnforcerCars;
static int32 &NumAmbulancesOnDuty;
diff --git a/src/control/Replay.cpp b/src/control/Replay.cpp
index 3ce9085f..29bdacd7 100644
--- a/src/control/Replay.cpp
+++ b/src/control/Replay.cpp
@@ -718,7 +718,7 @@ void CReplay::ProcessCarUpdate(CVehicle *vehicle, float interpolation, CAddressI
}
vehicle->bEngineOn = true;
if (vehicle->IsCar())
- ((CAutomobile*)vehicle)->m_nWheelsOnGround = 4;
+ ((CAutomobile*)vehicle)->m_nDriveWheelsOnGround = 4;
CWorld::Remove(vehicle);
CWorld::Add(vehicle);
if (vehicle->IsBoat())