diff options
author | Nikolay Korolev <nickvnuk@gmail.com> | 2020-10-18 14:39:27 +0200 |
---|---|---|
committer | Nikolay Korolev <nickvnuk@gmail.com> | 2020-10-18 14:39:27 +0200 |
commit | 8d92a0681ac6a55ccec3927eb29c3ccf665d62a9 (patch) | |
tree | 20fbd2ce24fd9e479718ecc1f739c43dcb5fb494 /src | |
parent | object field renamed (diff) | |
download | re3-8d92a0681ac6a55ccec3927eb29c3ccf665d62a9.tar re3-8d92a0681ac6a55ccec3927eb29c3ccf665d62a9.tar.gz re3-8d92a0681ac6a55ccec3927eb29c3ccf665d62a9.tar.bz2 re3-8d92a0681ac6a55ccec3927eb29c3ccf665d62a9.tar.lz re3-8d92a0681ac6a55ccec3927eb29c3ccf665d62a9.tar.xz re3-8d92a0681ac6a55ccec3927eb29c3ccf665d62a9.tar.zst re3-8d92a0681ac6a55ccec3927eb29c3ccf665d62a9.zip |
Diffstat (limited to 'src')
-rw-r--r-- | src/peds/PedAttractor.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/peds/PedAttractor.cpp b/src/peds/PedAttractor.cpp index 9f77f2a4..cebe31b0 100644 --- a/src/peds/PedAttractor.cpp +++ b/src/peds/PedAttractor.cpp @@ -135,8 +135,10 @@ void CPedAttractorManager::RemoveIceCreamVanEffects(C2dEffect* pEffect) if (vVehicleToEffect.empty()) return; for (std::vector<CVehicleToEffect>::const_iterator assoc = vVehicleToEffect.cbegin(); assoc != vVehicleToEffect.cend();) { - if (assoc->GetVehicle() != pVehicle) - return; + if (assoc->GetVehicle() != pVehicle) { + assoc++; + continue; + } uint32 total = 0; for (uint32 j = 0; j < NUM_ATTRACTORS_FOR_ICECREAM_VAN; j++) { if (FindAssociatedAttractor(assoc->GetEffect(j), vIceCreamAttractors)) |