Skip to content

Commit 6229fba

Browse files
committed
Distributed power: adaptation to Miletic's cabs
1 parent a215a71 commit 6229fba

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Source/Orts.Simulation/Simulation/RollingStocks/MSTSDieselLocomotive.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -889,7 +889,7 @@ public string GetDPDebugStatus()
889889
if (ThrottlePercent > 0)
890890
{
891891
if (ThrottleController.NotchCount() > 3)
892-
throttle = Simulator.Catalog.GetParticularString("Notch", "N") + ThrottleController.GetNearestNotch(ThrottlePercent / 100f);
892+
throttle = Simulator.Catalog.GetParticularString("Notch", "N") + MathHelper.Clamp(ThrottleController.GetNearestNotch(ThrottlePercent / 100f), 1, 8);
893893
else
894894
throttle = string.Format("{0:F0}%", ThrottlePercent);
895895
}

0 commit comments

Comments
 (0)