diff options
author | Sergeanur <s.anureev@yandex.ua> | 2020-05-05 17:32:46 +0200 |
---|---|---|
committer | Sergeanur <s.anureev@yandex.ua> | 2020-05-05 17:32:46 +0200 |
commit | 1eb817de7713ea95bbbcbd7543ffce61ced8ffec (patch) | |
tree | b0032de7a7452f49df7d03254e1e1c9f25b98f0d /src/control/CarCtrl.cpp | |
parent | Remove ColStore (diff) | |
download | re3-1eb817de7713ea95bbbcbd7543ffce61ced8ffec.tar re3-1eb817de7713ea95bbbcbd7543ffce61ced8ffec.tar.gz re3-1eb817de7713ea95bbbcbd7543ffce61ced8ffec.tar.bz2 re3-1eb817de7713ea95bbbcbd7543ffce61ced8ffec.tar.lz re3-1eb817de7713ea95bbbcbd7543ffce61ced8ffec.tar.xz re3-1eb817de7713ea95bbbcbd7543ffce61ced8ffec.tar.zst re3-1eb817de7713ea95bbbcbd7543ffce61ced8ffec.zip |
Diffstat (limited to '')
-rw-r--r-- | src/control/CarCtrl.cpp | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/control/CarCtrl.cpp b/src/control/CarCtrl.cpp index db6139b9..9b2bd4f0 100644 --- a/src/control/CarCtrl.cpp +++ b/src/control/CarCtrl.cpp @@ -696,7 +696,7 @@ CCarCtrl::PossiblyRemoveVehicle(CVehicle* pVehicle) if (pVehicle->bExtendedRange) threshold *= 1.5f; if (distanceToPlayer > threshold && !CGarages::IsPointWithinHideOutGarage(pVehicle->GetPosition())){ - if (pVehicle->GetIsOnScreenAndNotCulled()){ + if (pVehicle->GetIsOnScreen() && CRenderer::IsEntityCullZoneVisible(pVehicle)) { pVehicle->bFadeOut = true; }else{ CWorld::Remove(pVehicle); @@ -722,7 +722,7 @@ CCarCtrl::PossiblyRemoveVehicle(CVehicle* pVehicle) if (pVehicle->GetStatus() != STATUS_WRECKED || pVehicle->m_nTimeOfDeath == 0) return; if (CTimer::GetTimeInMilliseconds() > pVehicle->m_nTimeOfDeath + 60000 && - !pVehicle->GetIsOnScreenAndNotCulled()){ + !(pVehicle->GetIsOnScreen() && CRenderer::IsEntityCullZoneVisible(pVehicle)) ){ if ((pVehicle->GetPosition() - vecPlayerPos).MagnitudeSqr() > SQR(7.5f)){ if (!CGarages::IsPointWithinHideOutGarage(pVehicle->GetPosition())){ CWorld::Remove(pVehicle); @@ -2741,11 +2741,7 @@ bool CCarCtrl::ThisRoadObjectCouldMove(int16 mi) bool CCarCtrl::MapCouldMoveInThisArea(float x, float y) { -#ifdef GTA_BRIDGE // actually they forgot that in VC... // bridge moves up and down return x > -342.0f && x < -219.0f && y > -677.0f && y < -580.0f; -#else - return false; -#endif } |