Skip to content

Commit 1728ada

Browse files
committed
Automatic merge of T1.5.1-925-g1c557094e and 20 pull requests
- Pull request #570 at 3539862: Experimental glTF 2.0 support with PBR lighting - Pull request #799 at dfc715e: Consolidated wind simulation - Pull request #839 at d00beb9: First phase of https://blueprints.launchpad.net/or/+spec/additional-cruise-control-parameters - Pull request #876 at f92de76: docs: add source for documents previously on website to source Documentation folder - Pull request #882 at 3ca0eb1: Blueprint/train car operations UI window - Pull request #885 at 0a956f5: feat: Add notifications to Menu - Pull request #886 at 6c0785b: Scene viewer extension to TrackViewer - Pull request #892 at 1f5ba4c: Signal Function OPP_SIG_ID_TRAINPATH - Pull request #896 at 5866028: First implementation of https://blueprints.launchpad.net/or/+spec/specific-sounds-for-ai-trains - Pull request #903 at 7af1f91: Downloading route content (Github, zip) - Pull request #912 at f7b85e4: New Triple Valve Features Vol. 2 - Pull request #919 at 26cc6a8: Added mouse wheel support for controls which can be moved by pressing t… - Pull request #923 at cc1b5b6: Add curve squeal to route - Pull request #924 at 6c2c3cd: Default Asset Improvements - Pull request #925 at e3b1688: Fix brakeshoe force bug - Pull request #927 at 7bce293: AI Train Power Supply/Lights Fix - Pull request #929 at a406a69: Add support for common circuit breaker variants - Pull request #930 at 42398f4: Further enhancements for duplex locoomotive - Pull request #932 at 9bdb074: Changed matrix's to matrices - Pull request #933 at a3f56f4: Fix AI DM crashing
22 parents 01ad93c + 1c55709 + 3539862 + dfc715e + d00beb9 + f92de76 + 3ca0eb1 + 0a956f5 + 6c0785b + 1f5ba4c + 5866028 + 7af1f91 + f7b85e4 + 26cc6a8 + cc1b5b6 + 6c2c3cd + e3b1688 + 7bce293 + a406a69 + 42398f4 + 9bdb074 + a3f56f4 commit 1728ada

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

Source/Orts.Simulation/Simulation/RollingStocks/MSTSLocomotive.cs

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2017,9 +2017,6 @@ public override void Update(float elapsedClockSeconds)
20172017

20182018
// Pass Gearbox commands
20192019

2020-
2021-
2022-
20232020
// Note - at the moment there is only one GearBox Controller created, but a gearbox for each diesel engine is created.
20242021
// This code keeps all gearboxes in the locomotive aligned with the first engine and gearbox.
20252022
if (gearloco != null && gearloco.DieselTransmissionType == MSTSDieselLocomotive.DieselTransmissionTypes.Mechanic && GearBoxController.CurrentNotch != previousChangedGearBoxNotch)
@@ -2158,8 +2155,13 @@ public override void Update(float elapsedClockSeconds)
21582155
if (de.State != DieselEngineState.Running)
21592156
de.Initialize();
21602157
}
2158+
2159+
// if train is a geared locomotive then set it to automatic operation as AI driver can't operate manual gearboxes
21612160
if (de.GearBox != null)
21622161
de.GearBox.GearBoxOperation = GearBoxOperation.Automatic;
2162+
2163+
// Set gear to "low gear" at start.
2164+
de.GearBox.currentGearIndex = de.GearBox.NumOfGears - 1;
21632165
}
21642166
}
21652167
}

0 commit comments

Comments
 (0)