Compare commits
No commits in common. "2bef2a6c81816a4a50a751baf459e427a7dcd3a9" and "1dd95aff82ef57bb92aae0575c2458521b0b4d04" have entirely different histories.
2bef2a6c81
...
1dd95aff82
1
.gitignore
vendored
1
.gitignore
vendored
@ -7,4 +7,3 @@
|
|||||||
/bin/Release
|
/bin/Release
|
||||||
/bin/Debug
|
/bin/Debug
|
||||||
/packages/Newtonsoft.Json.13.0.1
|
/packages/Newtonsoft.Json.13.0.1
|
||||||
/.vs/edjournal/v17/.suo
|
|
||||||
|
@ -1,16 +0,0 @@
|
|||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
using System.Text;
|
|
||||||
using System.Threading.Tasks;
|
|
||||||
|
|
||||||
namespace EDJournal {
|
|
||||||
public class CommanderEntry : Entry {
|
|
||||||
public string Name { get; set; }
|
|
||||||
public string FID { get; set; }
|
|
||||||
protected override void Initialise() {
|
|
||||||
Name = JSON.Value<string>("Name") ?? "";
|
|
||||||
FID = JSON.Value<string>("FID") ?? "";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
1
Entry.cs
1
Entry.cs
@ -13,7 +13,6 @@ namespace EDJournal {
|
|||||||
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.Commander, typeof(CommanderEntry) },
|
|
||||||
{ Events.CommitCrime, typeof(CommitCrimeEntry) },
|
{ Events.CommitCrime, typeof(CommitCrimeEntry) },
|
||||||
{ Events.Died, typeof(DiedEntry) },
|
{ Events.Died, typeof(DiedEntry) },
|
||||||
{ Events.Docked, typeof(DockedEntry) },
|
{ Events.Docked, typeof(DockedEntry) },
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
namespace EDJournal {
|
namespace EDJournal {
|
||||||
public class Events {
|
public class Events {
|
||||||
public static readonly string Bounty = "Bounty";
|
public static readonly string Bounty = "Bounty";
|
||||||
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";
|
||||||
public static readonly string Docked = "Docked";
|
public static readonly string Docked = "Docked";
|
||||||
|
@ -6,8 +6,6 @@ namespace EDJournal {
|
|||||||
protected override void Initialise() {
|
protected override void Initialise() {
|
||||||
SystemAddress = JSON.Value<ulong?>("SystemAddress") ?? 0;
|
SystemAddress = JSON.Value<ulong?>("SystemAddress") ?? 0;
|
||||||
StarSystem = JSON.Value<string>("StarSystem");
|
StarSystem = JSON.Value<string>("StarSystem");
|
||||||
StarPos = JSON.Value<JArray>("StarPos").ToObject<long[]>();
|
|
||||||
|
|
||||||
var faction = JSON.Value<JObject>("SystemFaction");
|
var faction = JSON.Value<JObject>("SystemFaction");
|
||||||
if (faction != null) {
|
if (faction != null) {
|
||||||
SystemFaction = faction.Value<string>("Name");
|
SystemFaction = faction.Value<string>("Name");
|
||||||
@ -23,10 +21,12 @@ namespace EDJournal {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
public long[] StarPos { get; set; }
|
|
||||||
public string StarSystem { get; set; }
|
public string StarSystem { get; set; }
|
||||||
|
|
||||||
public string SystemFaction { get; set; }
|
public string SystemFaction { get; set; }
|
||||||
|
|
||||||
public ulong SystemAddress { get; set; }
|
public ulong SystemAddress { get; set; }
|
||||||
|
|
||||||
public List<Faction> SystemFactions { get; set; } = new List<Faction>();
|
public List<Faction> SystemFactions { get; set; } = new List<Faction>();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,6 @@ namespace EDJournal {
|
|||||||
public ulong SystemAddress { get; set; }
|
public ulong SystemAddress { get; set; }
|
||||||
public string Body { get; set; }
|
public string Body { get; set; }
|
||||||
public bool Docked { get; set; }
|
public bool Docked { get; set; }
|
||||||
public long[] StarPos { get; set; }
|
|
||||||
|
|
||||||
public List<Faction> SystemFactions { get; set; } = new List<Faction>();
|
public List<Faction> SystemFactions { get; set; } = new List<Faction>();
|
||||||
|
|
||||||
@ -22,7 +21,6 @@ namespace EDJournal {
|
|||||||
SystemAddress = JSON.Value<ulong?>("SystemAddress") ?? 0;
|
SystemAddress = JSON.Value<ulong?>("SystemAddress") ?? 0;
|
||||||
Docked = JSON.Value<bool?>("Docked") ?? false;
|
Docked = JSON.Value<bool?>("Docked") ?? false;
|
||||||
StationName = JSON.Value<string>("StationName") ?? "";
|
StationName = JSON.Value<string>("StationName") ?? "";
|
||||||
StarPos = JSON.Value<JArray>("StarPos").ToObject<long[]>();
|
|
||||||
|
|
||||||
JObject systemfaction = JSON.Value<JObject>("SystemFaction");
|
JObject systemfaction = JSON.Value<JObject>("SystemFaction");
|
||||||
if (systemfaction != null) {
|
if (systemfaction != null) {
|
||||||
|
@ -42,7 +42,6 @@
|
|||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Compile Include="BountyEntry.cs" />
|
<Compile Include="BountyEntry.cs" />
|
||||||
<Compile Include="CommanderEntry.cs" />
|
|
||||||
<Compile Include="CommitCrimeEntry.cs" />
|
<Compile Include="CommitCrimeEntry.cs" />
|
||||||
<Compile Include="Credits.cs" />
|
<Compile Include="Credits.cs" />
|
||||||
<Compile Include="CrimeTypes.cs" />
|
<Compile Include="CrimeTypes.cs" />
|
||||||
|
Loading…
Reference in New Issue
Block a user