EDBGS/EDPlayerJournal/Entries/BountyEntry.cs

26 lines
719 B
C#
Raw Permalink Normal View History

2022-11-01 18:01:28 +01:00
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace EDPlayerJournal.Entries;
/**
* This entry appears whenever a bounty is awarded.
*/
public class BountyEntry : Entry {
private string? victimfaction = null;
private string? target = null;
private int rewards = 0;
protected override void Initialise() {
rewards = JSON.Value<int?>("TotalReward") ?? 0;
victimfaction = JSON.Value<string>("VictimFaction") ?? "";
target = JSON.Value<string>("Target_Localised") ?? "";
}
public string? VictimFaction => victimfaction;
public string? Target => target;
public int Rewards => rewards;
}