summaryrefslogtreecommitdiffstats
path: root/src/vehicles/Train.cpp
diff options
context:
space:
mode:
authorSergeanur <s.anureev@yandex.ua>2020-06-15 16:44:47 +0200
committerSergeanur <s.anureev@yandex.ua>2020-06-15 16:44:47 +0200
commit655eaa36ce4dfbe3c8f7d46097d87d513a384b5f (patch)
treeaa16b934b8623fa16e0dcc149069a5e55115a345 /src/vehicles/Train.cpp
parentFix vehicle cam. zoom values (diff)
parentmore cleanup (diff)
downloadre3-655eaa36ce4dfbe3c8f7d46097d87d513a384b5f.tar
re3-655eaa36ce4dfbe3c8f7d46097d87d513a384b5f.tar.gz
re3-655eaa36ce4dfbe3c8f7d46097d87d513a384b5f.tar.bz2
re3-655eaa36ce4dfbe3c8f7d46097d87d513a384b5f.tar.lz
re3-655eaa36ce4dfbe3c8f7d46097d87d513a384b5f.tar.xz
re3-655eaa36ce4dfbe3c8f7d46097d87d513a384b5f.tar.zst
re3-655eaa36ce4dfbe3c8f7d46097d87d513a384b5f.zip
Diffstat (limited to 'src/vehicles/Train.cpp')
-rw-r--r--src/vehicles/Train.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/vehicles/Train.cpp b/src/vehicles/Train.cpp
index 50f7cb1d..546f72c2 100644
--- a/src/vehicles/Train.cpp
+++ b/src/vehicles/Train.cpp
@@ -663,8 +663,8 @@ PlayAnnouncement(uint8 sound, uint8 station)
void
ProcessTrainAnnouncements(void)
{
- for (int i = 0; i < 3; i++) {
- for (int j = 0; j < 3; j++) {
+ for (int i = 0; i < ARRAY_SIZE(StationDist); i++) {
+ for (int j = 0; j < ARRAY_SIZE(EngineTrackPosition); j++) {
if (!bTrainArrivalAnnounced[i]) {
float preDist = StationDist[i] - 100.0f;
if (preDist < 0.0f)