diff --git a/MarketSellEntry.cs b/MarketSellEntry.cs index df35e34..8ef41d8 100644 --- a/MarketSellEntry.cs +++ b/MarketSellEntry.cs @@ -1,11 +1,46 @@ namespace EDJournal { public class MarketSellEntry : Entry { - private int totalsale = 0; + /// + /// Total value + /// + public int TotalSale { get; set; } + /// + /// How many. + /// + public int Count { get; set; } + /// + /// Average price paid + /// + public int AvgPricePaid { get; set; } + /// + /// Cargo type + /// + public string Type { get; set; } + /// + /// Price per unit + /// + public int SellPrice { get; set; } + /// + /// Whether the goods were illegal in the target system. + /// + public bool IllegalGoods { get; set; } + /// + /// Whether the goods were stolen + /// + public bool StolenGoods { get; set; } + /// + /// Whether the goods were sold to the black market + /// + public bool BlackMarket { get; set; } protected override void Initialise() { - totalsale = JSON.Value("TotalSale"); + Type = JSON.Value("Type") ?? ""; + TotalSale = JSON.Value("TotalSale") ?? 0; + Count = JSON.Value("Count") ?? 0; + AvgPricePaid = JSON.Value("AvgPricePaid") ?? 0; + IllegalGoods = JSON.Value("IllegalGoods") ?? false; + StolenGoods = JSON.Value("StolenGoods") ?? false; + BlackMarket = JSON.Value("BlackMarket") ?? false; } - - public int TotalSale => totalsale; } }