Skip to content

Commit 77a649f

Browse files
authored
Merge pull request #1077 from cesarBLG/sme-regression-fix
Fix SME brakes not working
2 parents 39c4437 + 7e73abd commit 77a649f

File tree

1 file changed

+2
-2
lines changed
  • Source/Orts.Simulation/Simulation/Physics

1 file changed

+2
-2
lines changed

Source/Orts.Simulation/Simulation/Physics/Train.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -4104,7 +4104,7 @@ public void UnconditionalInitializeBrakes()
41044104
fullServPressurePSI = lead.BrakeSystem is VacuumSinglePipe ? 16 : maxPressurePSI - lead.TrainBrakeController.FullServReductionPSI;
41054105
EqualReservoirPressurePSIorInHg = Math.Min(maxPressurePSI, EqualReservoirPressurePSIorInHg);
41064106
lead.TrainBrakeController.UpdatePressure(ref EqualReservoirPressurePSIorInHg, 1000, ref BrakeLine4);
4107-
if (!(lead.BrakeSystem is EPBrakeSystem))
4107+
if (!(lead.BrakeSystem is EPBrakeSystem) && !(lead.BrakeSystem is SMEBrakeSystem))
41084108
BrakeLine4 = -1;
41094109
EqualReservoirPressurePSIorInHg =
41104110
MathHelper.Max(EqualReservoirPressurePSIorInHg, fullServPressurePSI);
@@ -4436,7 +4436,7 @@ public void PropagateBrakePressure(float elapsedClockSeconds)
44364436
if (lead.TrainBrakeController != null)
44374437
{
44384438
lead.TrainBrakeController.UpdatePressure(ref EqualReservoirPressurePSIorInHg, elapsedClockSeconds, ref BrakeLine4);
4439-
if (!(lead.BrakeSystem is EPBrakeSystem))
4439+
if (!(lead.BrakeSystem is EPBrakeSystem) && !(lead.BrakeSystem is SMEBrakeSystem))
44404440
BrakeLine4 = -1;
44414441
}
44424442
if (lead.EngineBrakeController != null)

0 commit comments

Comments
 (0)