summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorerorcun <erorcunerorcun@hotmail.com.tr>2021-02-28 15:18:48 +0100
committerSergeanur <s.anureev@yandex.ua>2021-06-24 20:32:39 +0200
commit8488dc791aa0f14958c2ac46bbf45e9812e14331 (patch)
treef3a0fd3b79f36c70b02722e4476f2e0f5271a76f /src
parentfix postfx (diff)
downloadre3-8488dc791aa0f14958c2ac46bbf45e9812e14331.tar
re3-8488dc791aa0f14958c2ac46bbf45e9812e14331.tar.gz
re3-8488dc791aa0f14958c2ac46bbf45e9812e14331.tar.bz2
re3-8488dc791aa0f14958c2ac46bbf45e9812e14331.tar.lz
re3-8488dc791aa0f14958c2ac46bbf45e9812e14331.tar.xz
re3-8488dc791aa0f14958c2ac46bbf45e9812e14331.tar.zst
re3-8488dc791aa0f14958c2ac46bbf45e9812e14331.zip
Diffstat (limited to 'src')
-rw-r--r--src/peds/Population.cpp7
-rw-r--r--src/vehicles/Automobile.cpp2
2 files changed, 4 insertions, 5 deletions
diff --git a/src/peds/Population.cpp b/src/peds/Population.cpp
index a0bf8be6..5bbb7c4b 100644
--- a/src/peds/Population.cpp
+++ b/src/peds/Population.cpp
@@ -945,10 +945,9 @@ CPopulation::MoveCarsAndPedsOutOfAbandonedZones()
void
CPopulation::ConvertAllObjectsToDummyObjects()
{
- int poolSize = CPools::GetObjectPool()->GetSize();
- for (int poolIndex = poolSize - 1; poolIndex >= 0; poolIndex--) {
-
- CObject *obj = CPools::GetObjectPool()->GetSlot(poolIndex);
+ uint32 i = CPools::GetObjectPool()->GetSize();
+ while(i--) {
+ CObject *obj = CPools::GetObjectPool()->GetSlot(i);
if (obj) {
if (obj->CanBeDeleted())
ConvertToDummyObject(obj);
diff --git a/src/vehicles/Automobile.cpp b/src/vehicles/Automobile.cpp
index c2cf26b9..c29c0536 100644
--- a/src/vehicles/Automobile.cpp
+++ b/src/vehicles/Automobile.cpp
@@ -4050,7 +4050,7 @@ CAutomobile::GetHeightAboveRoad(void)
void
CAutomobile::PlayCarHorn(void)
{
- int r;
+ uint32 r;
if(m_nCarHornTimer != 0)
return;