예제 #1
0
 // This overides the information for each individual wagon in the extended HUD
 public override string[] GetDebugStatus(Dictionary <BrakeSystemComponent, PressureUnit> units)
 {
     // display differently depending upon whether vacuum or air braked system
     if (Car.CarBrakeSystemType == "vacuum_piped")
     {
         return(new string[] {
             DebugType,
             string.Empty,
             FormatStrings.FormatPressure(Vac.FromPress(BrakeLine1PressurePSI), PressureUnit.InHg, PressureUnit.InHg, true),
             string.Empty,
             string.Empty, // Spacer because the state above needs 2 columns.
             HandbrakePercent > 0 ? string.Format("{0:F0}%", HandbrakePercent) : string.Empty,
             FrontBrakeHoseConnected ? "I" : "T",
             string.Format("A{0} B{1}", AngleCockAOpen ? "+" : "-", AngleCockBOpen ? "+" : "-"),
         });
     }
     else  // air braked by default
     {
         return(new string[] {
             DebugType,
             string.Empty,
             FormatStrings.FormatPressure(BrakeLine1PressurePSI, PressureUnit.PSI, units[BrakeSystemComponent.BrakePipe], true),
             string.Empty,
             string.Empty,
             string.Empty,
             string.Empty,
             string.Empty,
             string.Empty, // Spacer because the state above needs 2 columns.
             (Car as MSTSWagon).HandBrakePresent ? string.Format("{0:F0}%", HandbrakePercent) : string.Empty,
             FrontBrakeHoseConnected ? "I" : "T",
             string.Format("A{0} B{1}", AngleCockAOpen ? "+" : "-", AngleCockBOpen ? "+" : "-"),
             BleedOffValveOpen ? Simulator.Catalog.GetString("Open") : string.Empty,
         });
     }
 }
예제 #2
0
 public override string GetStatus(Dictionary <BrakeSystemComponent, PressureUnit> units)
 {
     // display differently depending upon whether vacuum or air braked system
     if (Car.CarBrakeSystemType == "vacuum_piped")
     {
         return(string.Format(" BP {0}", FormatStrings.FormatPressure(Vac.FromPress(BrakeLine1PressurePSI), PressureUnit.InHg, PressureUnit.InHg, false)));
     }
     else  // air braked by default
     {
         return(string.Format("BP {0}", FormatStrings.FormatPressure(BrakeLine1PressurePSI, PressureUnit.PSI, units[BrakeSystemComponent.BrakePipe], true)));
     }
 }
예제 #3
0
        // This overides the information for each individual wagon in the extended HUD
        public override string[] GetDebugStatus(Dictionary <BrakeSystemComponent, PressureUnit> units)
        {
            if (!(Car as MSTSWagon).NonAutoBrakePresent)
            {
                // display as a automatic vacuum brake

                return(new string[] {
                    "1V",
                    FormatStrings.FormatPressure(Vac.FromPress(CylPressurePSIA), PressureUnit.InHg, PressureUnit.InHg, true),
                    FormatStrings.FormatPressure(Vac.FromPress(BrakeLine1PressurePSI), PressureUnit.InHg, PressureUnit.InHg, true),
                    FormatStrings.FormatPressure(Vac.FromPress(VacResPressureAdjPSIA()), PressureUnit.InHg, PressureUnit.InHg, true),
                    string.Empty,
                    string.Empty,
                    string.Empty,
                    string.Empty,
                    string.Empty,
                    HandbrakePercent > 0 ? string.Format("{0:F0}%", HandbrakePercent) : string.Empty,
                    FrontBrakeHoseConnected? "I" : "T",
                    string.Format("A{0} B{1}", AngleCockAOpen? "+" : "-", AngleCockBOpen? "+" : "-"),
                });
            }
            else
            {
                // display as a straight vacuum brake

                return(new string[] {
                    "1VS",
                    FormatStrings.FormatPressure(Vac.FromPress(CylPressurePSIA), PressureUnit.InHg, PressureUnit.InHg, true),
                    FormatStrings.FormatPressure(Vac.FromPress(BrakeLine1PressurePSI), PressureUnit.InHg, PressureUnit.InHg, true),
                    string.Empty,
                    string.Empty,
                    string.Empty,
                    string.Empty,
                    string.Empty,
                    string.Empty,
                    HandbrakePercent > 0 ? string.Format("{0:F0}%", HandbrakePercent) : string.Empty,
                    FrontBrakeHoseConnected? "I" : "T",
                    string.Format("A{0} B{1}", AngleCockAOpen? "+" : "-", AngleCockBOpen? "+" : "-"),
                });
            }
        }