public override string GetInfo() { EntryCostDatabaseAccessor.Init(); EntryCostDatabaseAccessor.GetFields(); string data = null, APInfo = null; if (EntryCostDatabaseAccessor.GetHolder(part.name) is RealFuels.PartEntryCostHolder h) data = $"Total cost: {EntryCostDatabaseAccessor.GetCost(h)}\n{EntryCostDatabaseAccessor.DisplayHolder(h, false)}"; if (part.partInfo is AvailablePart ap) APInfo = $"Tech Required: {ap.TechRequired}"; string res = $"Part name: {part.name}\n{APInfo}\n{data}"; return res; }
public override string GetInfo() { EntryCostDatabaseAccessor.Init(); EntryCostDatabaseAccessor.GetFields(); string data = null, apInfo = null; if (EntryCostDatabaseAccessor.GetHolder(part.name) is RealFuels.PartEntryCostHolder h) { data = $"Total cost: {EntryCostDatabaseAccessor.GetCost(h)}\n{EntryCostDatabaseAccessor.DisplayHolder(h, false)}"; } if (part.partInfo is AvailablePart ap) { apInfo = $"Tech Required: {ap.TechRequired}"; if (part.CrewCapacity > 0) { apInfo = $"Training course: {TrainingDatabase.SynonymReplace(part.name)}\n{apInfo}"; } } string res = $"Part name: {part.name}\n{apInfo}\n{data}"; return(res); }