private void CalculateInfo() { string[] infoArr = { "MOT", MOT.ToString(), "Sat Nav", SatNav.ToString(), "Locked", Locked.ToString(), "Manufacturer", Manufacturer, "Model", Model, "Wheels", Wheels.ToString(), "Gears", Gears.ToString(), "Fuel Level", FuelLevel.ToString(), "Fuel Type", FuelType.ToString(), "EngineCC", Engine.EngineCC.ToString(), "Mileage", Engine.Mileage.ToString(), "Service Needed", Engine.ServiceNeeded.ToString() }; for (int i = 0; i < infoArr.Length; i++) { Info = Info + infoArr[i] + ": "; i++; Info = Info + infoArr[i] + "\n"; } }
} // True if real ED 2.2+ journal event and not pre 2.2 imported. public override void FillInformation(out string summary, out string info, out string detailed) //V { summary = "Jump to " + StarSystem; info = ""; if (JumpDist > 0) { info += JumpDist.ToString("0.00") + " ly"; } if (FuelUsed > 0) { info += ", Fuel " + FuelUsed.ToString("0.0") + "t"; } if (FuelLevel > 0) { info += " left " + FuelLevel.ToString("0.0") + "t"; } string econ = Economy_Localised.Alt(Economy); if (econ.Equals("None")) { econ = ""; } info += " "; info += BaseUtils.FieldBuilder.Build("Faction:", Faction, "State:", FactionState, "Allegiance:", Allegiance, "Economy:", econ, "Population:", Population); detailed = ""; if (Factions != null) { foreach (FactionInformation i in Factions) { detailed += BaseUtils.FieldBuilder.Build("", i.Name, "State:", i.FactionState, "Gov:", i.Government, "Inf:;%", (i.Influence * 100.0).ToString("0.0"), "Alg:", i.Allegiance); if (i.PendingStates != null) { detailed += BaseUtils.FieldBuilder.Build(",", "Pending State:"); foreach (JournalLocation.PowerStatesInfo state in i.PendingStates) { detailed += BaseUtils.FieldBuilder.Build(",", state.State, "", state.Trend); } } if (i.RecoveringStates != null) { detailed += BaseUtils.FieldBuilder.Build(",", "Recovering State:"); foreach (JournalLocation.PowerStatesInfo state in i.RecoveringStates) { detailed += BaseUtils.FieldBuilder.Build(",", state.State, "", state.Trend); } } detailed += Environment.NewLine; } } }
void CalculateInfo() { string[] infoArr = { "Wheels", Wheels.ToString(), "Top Speed", TopSpeed.ToString(), "Gears", Gears.ToString(), "Fuel Level", FuelLevel.ToString() }; for (int i = 0; i < infoArr.Length; i++) { Info = Info + infoArr[i] + ": "; i++; Info = Info + infoArr[i] + "\n"; } }
} // True if real ED 2.2+ journal event and not pre 2.2 imported. public override void FillInformation(out string summary, out string info, out string detailed) //V { summary = "Jump to " + StarSystem; info = ""; if (JumpDist > 0) { info += JumpDist.ToString("0.00") + " ly"; } if (FuelUsed > 0) { info += ", Fuel " + FuelUsed.ToString("0.0") + "t"; } if (FuelLevel > 0) { info += " left " + FuelLevel.ToString("0.0") + "t"; } string econ = Economy_Localised.Alt(Economy); if (econ.Equals("None")) { econ = ""; } info += " "; info += Tools.FieldBuilder("Faction:", Faction, "State:", FactionState, "Allegiance:", Allegiance, "Economy:", econ); detailed = ""; if (Factions != null) { foreach (FactionInformation i in Factions) { detailed += Tools.FieldBuilder("", i.Name, "State:", i.FactionState, "Gov:", i.Government, "Inf:;%", (i.Influence * 100.0).ToString("0.0"), "Alg:", i.Allegiance) + Environment.NewLine; } } }
public override void FillInformation(out string info, out string detailed) { StringBuilder sb = new StringBuilder(); if (JumpDist > 0) { sb.Append(JumpDist.ToString("0.00") + " ly"); } if (FuelUsed > 0) { sb.Append(", Fuel ".T(EDTx.JournalFSDJump_Fuel) + FuelUsed.ToString("0.0") + "t"); } if (FuelLevel > 0) { sb.Append(" left ".T(EDTx.JournalFSDJump_left) + FuelLevel.ToString("0.0") + "t"); } string econ = Economy_Localised.Alt(Economy); if (econ.Equals("None")) { econ = ""; } sb.Append(" "); sb.Append(BaseUtils.FieldBuilder.Build("Faction:".T(EDTx.JournalLocOrJump_Faction), Faction, "<;(Wanted) ".T(EDTx.JournalLocOrJump_Wanted), Wanted, "State:".T(EDTx.JournalLocOrJump_State), FactionState, "Allegiance:".T(EDTx.JournalLocOrJump_Allegiance), Allegiance, "Economy:".T(EDTx.JournalLocOrJump_Economy), econ, "Population:".T(EDTx.JournalLocOrJump_Population), Population)); info = sb.ToString(); sb.Clear(); if (Factions != null) { foreach (FactionInformation i in Factions) { sb.Append(BaseUtils.FieldBuilder.Build("", i.Name, "State:".T(EDTx.JournalLocOrJump_State), i.FactionState, "Government:".T(EDTx.JournalLocOrJump_Government), i.Government, "Inf:;%".T(EDTx.JournalLocOrJump_Inf), (i.Influence * 100.0).ToString("0.0"), "Allegiance:".T(EDTx.JournalLocOrJump_Allegiance), i.Allegiance, "Happiness:".T(EDTx.JournalLocOrJump_Happiness), i.Happiness_Localised, "Reputation:;%;N1".T(EDTx.JournalLocOrJump_Reputation), i.MyReputation, ";Squadron System".T(EDTx.JournalLocOrJump_SquadronSystem), i.SquadronFaction, ";Happiest System".T(EDTx.JournalLocOrJump_HappiestSystem), i.HappiestSystem, ";Home System".T(EDTx.JournalLocOrJump_HomeSystem), i.HomeSystem )); if (i.PendingStates != null) { sb.Append(BaseUtils.FieldBuilder.Build(",", "Pending State:".T(EDTx.JournalLocOrJump_PendingState))); foreach (JournalLocation.PowerStatesInfo state in i.PendingStates) { sb.Append(BaseUtils.FieldBuilder.Build(" ", state.State, "<(;)", state.Trend)); } } if (i.RecoveringStates != null) { sb.Append(BaseUtils.FieldBuilder.Build(",", "Recovering State:".T(EDTx.JournalLocOrJump_RecoveringState))); foreach (JournalLocation.PowerStatesInfo state in i.RecoveringStates) { sb.Append(BaseUtils.FieldBuilder.Build(" ", state.State, "<(;)", state.Trend)); } } if (i.ActiveStates != null) { sb.Append(BaseUtils.FieldBuilder.Build(",", "Active State:".T(EDTx.JournalLocOrJump_ActiveState))); foreach (JournalLocation.ActiveStatesInfo state in i.ActiveStates) { sb.Append(BaseUtils.FieldBuilder.Build(" ", state.State)); } } sb.Append(Environment.NewLine); } } detailed = sb.ToString(); }
public override void FillInformation(out string info, out string detailed) { StringBuilder sb = new StringBuilder(); if (JumpDist > 0) { sb.Append(JumpDist.ToString("0.00") + " ly"); } if (FuelUsed > 0) { sb.Append(", Fuel ".Tx(this) + FuelUsed.ToString("0.0") + "t"); } if (FuelLevel > 0) { sb.Append(" left ".Tx(this) + FuelLevel.ToString("0.0") + "t"); } string econ = Economy_Localised.Alt(Economy); if (econ.Equals("None")) { econ = ""; } sb.Append(" "); sb.Append(BaseUtils.FieldBuilder.Build("Faction:".Txb(this), Faction, "<;(Wanted) ".Txb(this), Wanted, "State:".Txb(this), FactionState, "Allegiance:".Txb(this), Allegiance, "Economy:".Txb(this), econ, "Population:".Txb(this), Population)); info = sb.ToString(); sb.Clear(); if (Factions != null) { foreach (FactionInformation i in Factions) { sb.Append(BaseUtils.FieldBuilder.Build("", i.Name, "State:".Txb(this), i.FactionState, "Government:".Txb(this), i.Government, "Inf:;%".Txb(this), (i.Influence * 100.0).ToString("0.0"), "Allegiance:".Txb(this), i.Allegiance)); if (i.PendingStates != null) { sb.Append(BaseUtils.FieldBuilder.Build(",", "Pending State:".Txb(this))); foreach (JournalLocation.PowerStatesInfo state in i.PendingStates) { sb.Append(BaseUtils.FieldBuilder.Build(",", state.State, "", state.Trend)); } } if (i.RecoveringStates != null) { sb.Append(BaseUtils.FieldBuilder.Build(",", "Recovering State:".Txb(this))); foreach (JournalLocation.PowerStatesInfo state in i.RecoveringStates) { sb.Append(BaseUtils.FieldBuilder.Build(",", state.State, "", state.Trend)); } } sb.Append(Environment.NewLine); } } detailed = sb.ToString(); }