summaryrefslogtreecommitdiffstats
path: root/src/vehicles/Vehicle.cpp
diff options
context:
space:
mode:
authorNikolay Korolev <nickvnuk@gmail.com>2020-05-05 13:40:35 +0200
committerNikolay Korolev <nickvnuk@gmail.com>2020-05-05 13:40:35 +0200
commitae0c83fa01b05dc2ee70acb2bd4d0e8a3945630c (patch)
tree12152b094647544a8b6bac68fe7271f37996afd5 /src/vehicles/Vehicle.cpp
parentMerge pull request #508 from Nick007J/master (diff)
downloadre3-ae0c83fa01b05dc2ee70acb2bd4d0e8a3945630c.tar
re3-ae0c83fa01b05dc2ee70acb2bd4d0e8a3945630c.tar.gz
re3-ae0c83fa01b05dc2ee70acb2bd4d0e8a3945630c.tar.bz2
re3-ae0c83fa01b05dc2ee70acb2bd4d0e8a3945630c.tar.lz
re3-ae0c83fa01b05dc2ee70acb2bd4d0e8a3945630c.tar.xz
re3-ae0c83fa01b05dc2ee70acb2bd4d0e8a3945630c.tar.zst
re3-ae0c83fa01b05dc2ee70acb2bd4d0e8a3945630c.zip
Diffstat (limited to '')
-rw-r--r--src/vehicles/Vehicle.cpp28
1 files changed, 27 insertions, 1 deletions
diff --git a/src/vehicles/Vehicle.cpp b/src/vehicles/Vehicle.cpp
index 75f43515..67024782 100644
--- a/src/vehicles/Vehicle.cpp
+++ b/src/vehicles/Vehicle.cpp
@@ -98,7 +98,10 @@ CVehicle::CVehicle(uint8 CreatedBy)
bHasAlreadyBeenRecorded = false;
m_bSirenOrAlarm = 0;
m_nCarHornTimer = 0;
- field_22D = 0;
+ m_nCarHornPattern = 0;
+#ifdef MIAMI
+ bParking = false;
+#endif
m_nAlarmState = 0;
m_nDoorLock = CARLOCK_UNLOCKED;
m_nLastWeaponDamage = -1;
@@ -118,6 +121,9 @@ CVehicle::CVehicle(uint8 CreatedBy)
AutoPilot.m_nTimeToStartMission = CTimer::GetTimeInMilliseconds();
AutoPilot.m_bStayInCurrentLevel = false;
AutoPilot.m_bIgnorePathfinding = false;
+#ifdef MIAMI
+ AutoPilot.m_nSwitchDistance = 20;
+#endif
}
CVehicle::~CVehicle()
@@ -1347,3 +1353,23 @@ CVehicle::Load(uint8*& buf)
SkipSaveBuf(buf, 99);
}
#endif
+
+#ifdef MIAMI
+eVehicleAppearance
+//--MIAMI: TODO, implement VC version, appearance != type
+// This would work for cars, boats and bikes but not for planes and helis
+CVehicle::GetVehicleAppearance(void)
+{
+ if (IsCar())
+ return VEHICLE_CAR;
+ if (IsBoat())
+ return VEHICLE_BOAT;
+ if (IsBike())
+ return VEHICLE_BIKE;
+ if (IsPlane())
+ return VEHICLE_PLANE;
+ if (IsHeli())
+ return VEHICLE_HELI;
+ return VEHICLE_NONE;
+}
+#endif