I cannot give you the log-file as line numbers in my version will differ from the official versions, so instead I will give you the code. It is quite easy to locate.
// // start cars moving backward when it is stationary, once it is moving it skips this whole section // for (int i = Cars.Count - 1; i >= 0; i--) { TrainCar car = Cars[i]; if (car.SpeedMpS != 0 || car.TotalForceN > (-1.0f * (car.FrictionForceN + car.BrakeForceN + car.CurveForceN + car.WindForceN + car.TunnelForceN))) { // Skip this section to start car if car is already moving, or force not sufficient to start it moving continue; } int j = i; float f = 0; float m = 0; for (; ; ) { // Cycle up the train consist until the first stationary car is found that has its leading couplers starting to pull it. The next car is then started by allowing its speed to increase above 0. f += car.TotalForceN + car.FrictionForceN + car.BrakeForceN + car.CurveForceN + car.WindForceN + car.TunnelForceN; m += car.MassKG; if (car.IsPlayerTrain && !Simulator.Settings.SimpleControlPhysics && car.IsAdvancedCoupler) // "Advanced coupler" - operates in three extension zones { if (j == 0 || car.CouplerSlackM > car.AdvancedCouplerDynamicCompressionSlackLimitM) break; } else // Simple coupler { if (j == 0 || car.CouplerSlackM > -car.GetMaximumSimpleCouplerSlack2M()) break; } j--; // Decrement the count so that next car is started car = Cars[j]; } if (f < 0) { for (int k = j; k <= i; k++) { if ((Cars[k].CarBrakeSystemType == "air_piped" || Cars[k].CarBrakeSystemType == "vacuum_piped" || car.CarBrakeSystemType == "manual_braking") && FirstCar.SpeedMpS > 0 && Cars[k - 1].SpeedMpS == 0.0) <==== CRASH { // If is manual braked, air_piped car or vacuum_piped, and preceeding car is at stop, then set speed to zero. These type of cars do not have any brake force to hold them still Cars[k].SpeedMpS = 0.0f; } else { // Start this stationary car Cars[k].SpeedMpS = f / m * elapsedTime; } } } } }
In the code above, I have indicated the line where the crash occurs.
Looking into this (using some additional print statements), what happens is that the first loop (for ( ; ; ; )) exits with j=0.
In that case, the second loop (for (int k = j; k <= i; k++)) runs from 0 to 1, and not surprisingly, the IF statement then crashes on Cars[k-1].
The crash occurs as cars are attached, for the previous update showed the train had 7 cars, but at the moment of the crash it has 10 cars.
The crash occured on the New Forest route, just after 09:15. Restarting from saved sessions just before it happened (thanks to my auto-save), it was consistent. But that does not mean it is also consistent when starting completely fresh.
Regards,
Rob Roeterdink