Skip to content

Commit 848dab4

Browse files
authored
Merge pull request #1099 from cesarBLG/fix-tcs-pantographs
Fix TCS orders not being sent to pantographs
2 parents 08d1e2f + 5e8b056 commit 848dab4

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Source/Orts.Simulation/Simulation/RollingStocks/SubSystems/TrainControlSystem.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -432,7 +432,7 @@ public void Initialize()
432432
{
433433
if (Locomotive.Pantographs.State == PantographState.Up)
434434
{
435-
Locomotive.LocomotivePowerSupply.HandleEvent(PowerSupplyEvent.LowerPantograph);
435+
Locomotive.LocomotivePowerSupply.HandleEventFromTcs(PowerSupplyEvent.LowerPantograph);
436436
}
437437
};
438438
Script.SetPantographUp = (pantoID) =>
@@ -442,7 +442,7 @@ public void Initialize()
442442
Trace.TraceError($"TCS script used bad pantograph ID {pantoID}");
443443
return;
444444
}
445-
Locomotive.LocomotivePowerSupply.HandleEvent(PowerSupplyEvent.RaisePantograph, pantoID);
445+
Locomotive.LocomotivePowerSupply.HandleEventFromTcs(PowerSupplyEvent.RaisePantograph, pantoID);
446446
};
447447
Script.SetPantographDown = (pantoID) =>
448448
{
@@ -451,7 +451,7 @@ public void Initialize()
451451
Trace.TraceError($"TCS script used bad pantograph ID {pantoID}");
452452
return;
453453
}
454-
Locomotive.LocomotivePowerSupply.HandleEvent(PowerSupplyEvent.LowerPantograph, pantoID);
454+
Locomotive.LocomotivePowerSupply.HandleEventFromTcs(PowerSupplyEvent.LowerPantograph, pantoID);
455455
};
456456
Script.SetPowerAuthorization = (value) => PowerAuthorization = value;
457457
Script.SetCircuitBreakerClosingOrder = (value) => CircuitBreakerClosingOrder = value;

0 commit comments

Comments
 (0)