summaryrefslogtreecommitdiffstats
path: root/src/control/Script.cpp
diff options
context:
space:
mode:
authorNikolay Korolev <nickvnuk@gmail.com>2020-06-08 00:16:21 +0200
committerNikolay Korolev <nickvnuk@gmail.com>2020-06-08 00:16:21 +0200
commitaf564d865c3883f11a5272be76f3a51863586a8d (patch)
tree24a2c4d90909c20c34eb9e666818df6b011189dd /src/control/Script.cpp
parentfixed some arithmetic (diff)
downloadre3-af564d865c3883f11a5272be76f3a51863586a8d.tar
re3-af564d865c3883f11a5272be76f3a51863586a8d.tar.gz
re3-af564d865c3883f11a5272be76f3a51863586a8d.tar.bz2
re3-af564d865c3883f11a5272be76f3a51863586a8d.tar.lz
re3-af564d865c3883f11a5272be76f3a51863586a8d.tar.xz
re3-af564d865c3883f11a5272be76f3a51863586a8d.tar.zst
re3-af564d865c3883f11a5272be76f3a51863586a8d.zip
Diffstat (limited to 'src/control/Script.cpp')
-rw-r--r--src/control/Script.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/control/Script.cpp b/src/control/Script.cpp
index d90f2a0b..da321a28 100644
--- a/src/control/Script.cpp
+++ b/src/control/Script.cpp
@@ -2153,7 +2153,7 @@ int8 CRunningScript::ProcessCommands100To199(int32 command)
car->AutoPilot.m_nCarMission = MISSION_GOTOCOORDS;
car->SetStatus(STATUS_PHYSICS);
car->bEngineOn = true;
- car->AutoPilot.m_nCruiseSpeed = Max(car->AutoPilot.m_nCruiseSpeed, 6);
+ car->AutoPilot.m_nCruiseSpeed = Max(6, car->AutoPilot.m_nCruiseSpeed);
car->AutoPilot.m_nAntiReverseTimer = CTimer::GetTimeInMilliseconds();
return 0;
}
@@ -2165,7 +2165,7 @@ int8 CRunningScript::ProcessCommands100To199(int32 command)
CCarCtrl::JoinCarWithRoadSystem(car);
car->AutoPilot.m_nCarMission = MISSION_CRUISE;
car->bEngineOn = true;
- car->AutoPilot.m_nCruiseSpeed = Max(car->AutoPilot.m_nCruiseSpeed, 6);
+ car->AutoPilot.m_nCruiseSpeed = Max(6, car->AutoPilot.m_nCruiseSpeed);
car->AutoPilot.m_nAntiReverseTimer = CTimer::GetTimeInMilliseconds();
return 0;
}