public override string GetDebugStatus() { var status = new StringBuilder(base.GetDebugStatus()); if (DieselEngines.HasGearBox) { status.AppendFormat("\t{0} {1}", Simulator.Catalog.GetString("Gear"), DieselEngines[0].GearBox.CurrentGearIndex); } status.AppendFormat("\t{0} {1}\t\t{2}", Simulator.Catalog.GetString("Fuel"), FormatStrings.FormatFuelVolume(DieselLevelL, IsMetric, IsUK), DieselEngines.GetStatus()); if (IsSteamHeatFitted && TrainFittedSteamHeat && this.IsLeadLocomotive() && Train.PassengerCarsNumber > 0) { // Only show steam heating HUD if fitted to locomotive and the train, has passenger cars attached, and is the lead locomotive // Display Steam Heat info status.AppendFormat("\n{0}\t{1}\t{2}\t{3}\t{4}\t{5}\t{6}\t{7}\t{8}\t{9}\t{10:N0}\t{11}\t{12}\n", Simulator.Catalog.GetString("StHeat:"), Simulator.Catalog.GetString("Press"), FormatStrings.FormatPressure(CurrentSteamHeatPressurePSI, PressureUnit.PSI, MainPressureUnit, true), Simulator.Catalog.GetString("TrTemp"), FormatStrings.FormatTemperature(Train.TrainCurrentCarriageHeatTempC, IsMetric, false), Simulator.Catalog.GetString("StTemp"), FormatStrings.FormatTemperature(Train.TrainCurrentSteamHeatPipeTempC, IsMetric, false), Simulator.Catalog.GetString("OutTemp"), FormatStrings.FormatTemperature(Train.TrainOutsideTempC, IsMetric, false), Simulator.Catalog.GetString("NetHt"), Train.DisplayTrainNetSteamHeatLossWpTime, Simulator.Catalog.GetString("FuelLvl"), CurrentSteamHeatFuelCapacityL); } return(status.ToString()); }
public string GetStatus() { var result = new StringBuilder(); result.AppendFormat(Simulator.Catalog.GetString("Status")); foreach (var eng in DEList) { result.AppendFormat("\t{0}", Simulator.Catalog.GetString(GetStringAttribute.GetPrettyName(eng.EngineStatus))); } result.AppendFormat("\t{0}\t{1}", Simulator.Catalog.GetParticularString("HUD", "Power"), FormatStrings.FormatPower(MaxOutputPowerW, Locomotive.IsMetric, false, false)); foreach (var eng in DEList) { result.AppendFormat("\t{0}", FormatStrings.FormatPower(eng.MaxOutputPowerW, Locomotive.IsMetric, false, false)); } result.AppendFormat("\t{0}", Simulator.Catalog.GetString("Load")); foreach (var eng in DEList) { result.AppendFormat("\t{0:F1}%", eng.LoadPercent); } foreach (var eng in DEList) { result.AppendFormat("\t{0:F0} {1}", eng.RealRPM, FormatStrings.rpm); } result.AppendFormat("\t{0}", Simulator.Catalog.GetString("Flow")); foreach (var eng in DEList) { result.AppendFormat("\t{0}/{1}", FormatStrings.FormatFuelVolume(pS.TopH(eng.DieselFlowLps), Locomotive.IsMetric, Locomotive.IsUK), FormatStrings.h); } result.Append("\t"); foreach (var eng in DEList) { result.AppendFormat("\t{0}", FormatStrings.FormatTemperature(eng.DieselTemperatureDeg, Locomotive.IsMetric, false)); } result.AppendFormat("\t{0}", Simulator.Catalog.GetString("Oil")); foreach (var eng in DEList) { result.AppendFormat("\t{0}", FormatStrings.FormatPressure(eng.DieselOilPressurePSI, PressureUnit.PSI, Locomotive.MainPressureUnit, true)); } return(result.ToString()); }
public override string GetDebugStatus() { var status = new StringBuilder(base.GetDebugStatus()); status.AppendFormat("\t{0}\t\t{1}", Simulator.Catalog.GetString("Circuit breaker"), Simulator.Catalog.GetParticularString("CircuitBreaker", GetStringAttribute.GetPrettyName(ElectricPowerSupply.CircuitBreaker.State))); status.AppendFormat("\t{0}\t{1}", Simulator.Catalog.GetString("TCS"), ElectricPowerSupply.CircuitBreaker.TCSClosingAuthorization ? Simulator.Catalog.GetString("OK") : Simulator.Catalog.GetString("NOT OK")); status.AppendFormat("\t{0}\t{1}", Simulator.Catalog.GetString("Driver"), ElectricPowerSupply.CircuitBreaker.DriverClosingAuthorization ? Simulator.Catalog.GetString("OK") : Simulator.Catalog.GetString("NOT OK")); status.AppendFormat("\t{0}\t\t{1}\n", Simulator.Catalog.GetString("Auxiliary power"), Simulator.Catalog.GetParticularString("PowerSupply", GetStringAttribute.GetPrettyName(LocomotivePowerSupply.AuxiliaryPowerSupplyState))); if (IsSteamHeatFitted && Train.PassengerCarsNumber > 0 && this.IsLeadLocomotive() && Train.CarSteamHeatOn) { // Only show steam heating HUD if fitted to locomotive and the train, has passenger cars attached, and is the lead locomotive // Display Steam Heat info status.AppendFormat("{0}\t{1}\t{2}\t{3}\t{4}\t{5}\t{6}/{7}\t{8}\t{9}\t{10}\t{11}\t{12}\t{13}\t{14}\t{15}\t{16}\t{17}\t{18:N0}\n", Simulator.Catalog.GetString("StHeat:"), Simulator.Catalog.GetString("Press"), FormatStrings.FormatPressure(CurrentSteamHeatPressurePSI, PressureUnit.PSI, MainPressureUnit, true), Simulator.Catalog.GetString("StTemp"), FormatStrings.FormatTemperature(C.FromF(SteamHeatPressureToTemperaturePSItoF[CurrentSteamHeatPressurePSI]), IsMetric, false), Simulator.Catalog.GetString("StUse"), FormatStrings.FormatMass(pS.TopH(Kg.FromLb(CalculatedCarHeaterSteamUsageLBpS)), IsMetric), FormatStrings.h, Simulator.Catalog.GetString("WaterLvl"), FormatStrings.FormatFuelVolume(CurrentLocomotiveSteamHeatBoilerWaterCapacityL, IsMetric, IsUK), Simulator.Catalog.GetString("Last:"), Simulator.Catalog.GetString("Press"), FormatStrings.FormatPressure(Train.LastCar.CarSteamHeatMainPipeSteamPressurePSI, PressureUnit.PSI, MainPressureUnit, true), Simulator.Catalog.GetString("Temp"), FormatStrings.FormatTemperature(Train.LastCar.CarInsideTempC, IsMetric, false), Simulator.Catalog.GetString("OutTemp"), FormatStrings.FormatTemperature(CarOutsideTempC, IsMetric, false), Simulator.Catalog.GetString("NetHt"), Train.LastCar.CarNetHeatFlowRateW); } return(status.ToString()); }
public override string GetDebugStatus() { var status = new StringBuilder(base.GetDebugStatus()); status.AppendFormat("\t{0}\t\t", Simulator.Catalog.GetParticularString("CircuitBreaker", PowerSupply.CircuitBreaker.State.GetDescription())); status.AppendFormat("{0}\t", PowerSupply.CircuitBreaker.TCSClosingAuthorization ? Simulator.Catalog.GetString("OK") : Simulator.Catalog.GetString("NOT OK")); status.AppendFormat("{0}\t", PowerSupply.CircuitBreaker.DriverClosingAuthorization ? Simulator.Catalog.GetString("OK") : Simulator.Catalog.GetString("NOT OK")); status.AppendFormat("\t{0}\t\t{1}\n", Simulator.Catalog.GetString("Auxiliary power"), Simulator.Catalog.GetParticularString("PowerSupply", PowerSupply.AuxiliaryState.GetDescription())); if (IsSteamHeatFitted && Train.PassengerCarsNumber > 0 && this.IsLeadLocomotive() && Train.CarSteamHeatOn) { // Only show steam heating HUD if fitted to locomotive and the train, has passenger cars attached, and is the lead locomotive // Display Steam Heat info status.AppendFormat("{0}\t{1}\t{2}\t{3}\t{4}\t{5}\t{6}/{7}\t{8}\t{9}\t{10}\t{11}\t{12}\t{13}\t{14}\t{15}\t{16}\t{17}\t{18:N0}\n", Simulator.Catalog.GetString("StHeat:"), Simulator.Catalog.GetString("Press"), FormatStrings.FormatPressure(CurrentSteamHeatPressurePSI, Pressure.Unit.PSI, MainPressureUnit, true), Simulator.Catalog.GetString("StTemp"), FormatStrings.FormatTemperature(Temperature.Celsius.FromF(SteamHeatPressureToTemperaturePSItoF[CurrentSteamHeatPressurePSI]), IsMetric), Simulator.Catalog.GetString("StUse"), FormatStrings.FormatMass(Frequency.Periodic.ToHours(Mass.Kilogram.FromLb(CalculatedCarHeaterSteamUsageLBpS)), IsMetric), FormatStrings.h, Simulator.Catalog.GetString("WaterLvl"), FormatStrings.FormatFuelVolume(CurrentLocomotiveSteamHeatBoilerWaterCapacityL, IsMetric, IsUK), Simulator.Catalog.GetString("Last:"), Simulator.Catalog.GetString("Press"), FormatStrings.FormatPressure(Train.LastCar.CarSteamHeatMainPipeSteamPressurePSI, Pressure.Unit.PSI, MainPressureUnit, true), Simulator.Catalog.GetString("Temp"), FormatStrings.FormatTemperature(Train.LastCar.CarCurrentCarriageHeatTempC, IsMetric), Simulator.Catalog.GetString("OutTemp"), FormatStrings.FormatTemperature(Train.TrainOutsideTempC, IsMetric), Simulator.Catalog.GetString("NetHt"), Train.LastCar.DisplayTrainNetSteamHeatLossWpTime); } return(status.ToString()); }
public override string GetDebugStatus() { var status = new StringBuilder(base.GetDebugStatus()); if (DieselEngines.HasGearBox) { status.AppendFormat("\t{0} {1}", Simulator.Catalog.GetString("Gear"), DieselEngines[0].GearBox.CurrentGearIndex); } status.AppendFormat("\t{0} {1}\t\t\t{2}", Simulator.Catalog.GetString("Fuel"), FormatStrings.FormatFuelVolume(DieselLevelL, IsMetric, IsUK), DieselEngines.GetStatus()); return(status.ToString()); }