@@ -273,18 +273,6 @@ public static Event From(bool mstsBinEnabled, Source source, int eventID)
273273 switch ( source )
274274 {
275275 case Source . MSTSCar :
276- if ( mstsBinEnabled )
277- {
278- switch ( eventID )
279- {
280- // MSTSBin codes (documented at http://mstsbin.uktrainsim.com/)
281- case 23 : return Event . EnginePowerOn ;
282- case 24 : return Event . EnginePowerOff ;
283- case 66 : return Event . Pantograph2Up ;
284- case 67 : return Event . Pantograph2Down ;
285- default : break ;
286- }
287- }
288276 switch ( eventID )
289277 {
290278 // Calculated from inspection of existing engine .sms files and extensive testing.
@@ -310,8 +298,9 @@ public static Event From(bool mstsBinEnabled, Source source, int eventID)
310298 case 20 : return Event . DynamicBrakeChange ;
311299 case 21 : return Event . EngineBrakePressureIncrease ; // Event 21 is defined in sound files but never used in MSTS.
312300 case 22 : return Event . EngineBrakePressureDecrease ; // Event 22 is defined in sound files but never used in MSTS.
313- // Event 23 is unused in MSTS.
314- // Event 24 is unused in MSTS.
301+ // MSTSBin codes 23, 24 (documented at http://mstsbin.uktrainsim.com/)
302+ case 23 : return Event . EnginePowerOn ;
303+ case 24 : return Event . EnginePowerOff ;
315304 // Event 25 is possibly a vigilance reset in MSTS sound files but is never used.
316305 // Event 26 is a sander toggle in MSTS sound files but is never used.
317306 case 27 : return Event . WaterInjector2On ;
@@ -352,6 +341,9 @@ public static Event From(bool mstsBinEnabled, Source source, int eventID)
352341 case 62 : return Event . UncoupleB ;
353342 case 63 : return Event . UncoupleC ;
354343 // Event 64 is unused in MSTS.
344+ // MSTSBin codes 66, 67 (documented at http://mstsbin.uktrainsim.com/)
345+ case 66 : return Event . Pantograph2Up ;
346+ case 67 : return Event . Pantograph2Down ;
355347
356348 // ORTS only Events
357349 case 101 : return Event . GearUp ; // for gearbox based engines
0 commit comments