add capshipbond entry
This commit is contained in:
parent
dd1d7ff091
commit
12ba6d4d96
24
EDPlayerJournal/Entries/CapShipBondEntry.cs
Normal file
24
EDPlayerJournal/Entries/CapShipBondEntry.cs
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
namespace EDPlayerJournal.Entries;
|
||||||
|
|
||||||
|
public class CapShipBondEntry : Entry {
|
||||||
|
/// <summary>
|
||||||
|
/// Reward gained
|
||||||
|
/// </summary>
|
||||||
|
public ulong Reward { get; set; } = 0;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Victim faction, i.e. to whom the cap ship belongs
|
||||||
|
/// </summary>
|
||||||
|
public string? VictimFaction { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Awarding faction.
|
||||||
|
/// </summary>
|
||||||
|
public string? AwardingFaction { get; set; }
|
||||||
|
|
||||||
|
protected override void Initialise() {
|
||||||
|
Reward = JSON.Value<ulong?>("Reward") ?? 0;
|
||||||
|
VictimFaction = JSON.Value<string?>("VictimFaction");
|
||||||
|
AwardingFaction = JSON.Value<string?>("AwardingFaction");
|
||||||
|
}
|
||||||
|
}
|
@ -13,6 +13,7 @@ namespace EDPlayerJournal.Entries;
|
|||||||
public class Entry {
|
public class Entry {
|
||||||
private static readonly Dictionary<string, Type> classes = new Dictionary<string, Type> {
|
private static readonly Dictionary<string, Type> classes = new Dictionary<string, Type> {
|
||||||
{ Events.Bounty, typeof(BountyEntry) },
|
{ Events.Bounty, typeof(BountyEntry) },
|
||||||
|
{ Events.CapShipBond, typeof(CapShipBondEntry) },
|
||||||
{ Events.Commander, typeof(CommanderEntry) },
|
{ Events.Commander, typeof(CommanderEntry) },
|
||||||
{ Events.CommitCrime, typeof(CommitCrimeEntry) },
|
{ Events.CommitCrime, typeof(CommitCrimeEntry) },
|
||||||
{ Events.Died, typeof(DiedEntry) },
|
{ Events.Died, typeof(DiedEntry) },
|
||||||
|
@ -2,6 +2,7 @@
|
|||||||
|
|
||||||
public class Events {
|
public class Events {
|
||||||
public static readonly string Bounty = "Bounty";
|
public static readonly string Bounty = "Bounty";
|
||||||
|
public static readonly string CapShipBond = "CapShipBond";
|
||||||
public static readonly string Commander = "Commander";
|
public static readonly string Commander = "Commander";
|
||||||
public static readonly string CommitCrime = "CommitCrime";
|
public static readonly string CommitCrime = "CommitCrime";
|
||||||
public static readonly string Died = "Died";
|
public static readonly string Died = "Died";
|
||||||
|
Loading…
Reference in New Issue
Block a user