summaryrefslogtreecommitdiffstats
path: root/src/control
diff options
context:
space:
mode:
authorNikolay Korolev <nickvnuk@gmail.com>2019-08-14 21:35:02 +0200
committerNikolay Korolev <nickvnuk@gmail.com>2019-08-14 21:35:02 +0200
commit291f73e3c79e4feb64f63eed5bae7ca144fcf865 (patch)
tree9284dab4748f27af5b05f95b76e18e52cb5ccd47 /src/control
parentMerge pull request #188 from erorcun/erorcun (diff)
downloadre3-291f73e3c79e4feb64f63eed5bae7ca144fcf865.tar
re3-291f73e3c79e4feb64f63eed5bae7ca144fcf865.tar.gz
re3-291f73e3c79e4feb64f63eed5bae7ca144fcf865.tar.bz2
re3-291f73e3c79e4feb64f63eed5bae7ca144fcf865.tar.lz
re3-291f73e3c79e4feb64f63eed5bae7ca144fcf865.tar.xz
re3-291f73e3c79e4feb64f63eed5bae7ca144fcf865.tar.zst
re3-291f73e3c79e4feb64f63eed5bae7ca144fcf865.zip
Diffstat (limited to 'src/control')
-rw-r--r--src/control/CarCtrl.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/control/CarCtrl.cpp b/src/control/CarCtrl.cpp
index d2d3ed5f..0df42397 100644
--- a/src/control/CarCtrl.cpp
+++ b/src/control/CarCtrl.cpp
@@ -47,7 +47,7 @@ int32 &CCarCtrl::MaxNumberOfCarsInUse = *(int32*)0x5EC8B8;
uint32 &CCarCtrl::LastTimeLawEnforcerCreated = *(uint32*)0x8F5FF0;
int32 (&CCarCtrl::TotalNumOfCarsOfRating)[7] = *(int32(*)[7])*(uintptr*)0x8F1A60;
int32 (&CCarCtrl::NextCarOfRating)[7] = *(int32(*)[7])*(uintptr*)0x9412AC;
-int32 (&CCarCtrl::CarArrays)[7][256] = *(int32(*)[7][256])*(uintptr*)0x6EB860;
+int32 (&CCarCtrl::CarArrays)[7][MAX_CAR_MODELS_IN_ARRAY] = *(int32(*)[7][MAX_CAR_MODELS_IN_ARRAY])*(uintptr*)0x6EB860;
CVehicle* (&apCarsToKeep)[MAX_CARS_TO_KEEP] = *(CVehicle*(*)[MAX_CARS_TO_KEEP])*(uintptr*)0x70D830;
WRAPPER void CCarCtrl::SwitchVehicleToRealPhysics(CVehicle*) { EAXJMP(0x41F7F0); }
@@ -694,7 +694,7 @@ CCarCtrl::PossiblyRemoveVehicle(CVehicle* pVehicle)
if (pVehicle->m_status != STATUS_WRECKED || pVehicle->m_nTimeOfDeath == 0)
return;
if (CTimer::GetTimeInMilliseconds() > pVehicle->m_nTimeOfDeath + 60000 &&
- (!pVehicle->GetIsOnScreen() || CRenderer::IsEntityCullZoneVisible(pVehicle))){
+ (!pVehicle->GetIsOnScreen() || !CRenderer::IsEntityCullZoneVisible(pVehicle))){
if ((pVehicle->GetPosition() - vecPlayerPos).MagnitudeSqr() > SQR(7.5f)){
if (!CGarages::IsPointWithinHideOutGarage(&pVehicle->GetPosition())){
CWorld::Remove(pVehicle);