summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorNikolay Korolev <nickvnuk@gmail.com>2020-09-28 20:25:14 +0200
committerNikolay Korolev <nickvnuk@gmail.com>2020-09-28 20:25:14 +0200
commit742ca47a436632eb84de925c8d3386b7bc7dd2d2 (patch)
tree8cbd7c5bb9aa70cc71a66dfdaaad3048d3d4a798 /src
parentMerge pull request #722 from theR4K/master (diff)
downloadre3-742ca47a436632eb84de925c8d3386b7bc7dd2d2.tar
re3-742ca47a436632eb84de925c8d3386b7bc7dd2d2.tar.gz
re3-742ca47a436632eb84de925c8d3386b7bc7dd2d2.tar.bz2
re3-742ca47a436632eb84de925c8d3386b7bc7dd2d2.tar.lz
re3-742ca47a436632eb84de925c8d3386b7bc7dd2d2.tar.xz
re3-742ca47a436632eb84de925c8d3386b7bc7dd2d2.tar.zst
re3-742ca47a436632eb84de925c8d3386b7bc7dd2d2.zip
Diffstat (limited to 'src')
-rw-r--r--src/vehicles/CarGen.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/vehicles/CarGen.cpp b/src/vehicles/CarGen.cpp
index dd727e2b..5de478b7 100644
--- a/src/vehicles/CarGen.cpp
+++ b/src/vehicles/CarGen.cpp
@@ -28,7 +28,7 @@ void CCarGenerator::SwitchOff()
void CCarGenerator::SwitchOn()
{
- m_nUsesRemaining = 255;
+ m_nUsesRemaining = UINT16_MAX;
m_nTimer = CalcNextGen();
++CTheCarGenerators::CurrentActiveCount;
}
@@ -111,10 +111,10 @@ void CCarGenerator::DoInternalProcessing()
}
}
#ifdef FIX_BUGS
- if (m_nUsesRemaining != 0)
+ if (m_nUsesRemaining < UINT16_MAX)
--m_nUsesRemaining;
#else
- if (m_nUsesRemaining < -1)
+ if (m_nUsesRemaining < ~0)
--m_nUsesRemaining;
#endif
m_nTimer = CalcNextGen();