From 1f86ef9c7bf036e82e5de3db2956515becf92d30 Mon Sep 17 00:00:00 2001 From: andylippitt Date: Sun, 3 Mar 2019 11:08:53 -0500 Subject: [PATCH] world qualified logging --- Game.Engine/Auditing/AuditEventBase.cs | 2 ++ Game.Engine/Auditing/AuditEventDeath.cs | 3 +++ Game.Engine/Auditing/AuditEventSpawn.cs | 2 ++ 3 files changed, 7 insertions(+) diff --git a/Game.Engine/Auditing/AuditEventBase.cs b/Game.Engine/Auditing/AuditEventBase.cs index 8b6fb91f..e881777a 100644 --- a/Game.Engine/Auditing/AuditEventBase.cs +++ b/Game.Engine/Auditing/AuditEventBase.cs @@ -3,5 +3,7 @@ public class AuditEventBase { public string Type { get => this.GetType().Name; } + public string PublicURL { get; set; } + public string WorldKey { get; set; } } } diff --git a/Game.Engine/Auditing/AuditEventDeath.cs b/Game.Engine/Auditing/AuditEventDeath.cs index a970807b..a35ce632 100644 --- a/Game.Engine/Auditing/AuditEventDeath.cs +++ b/Game.Engine/Auditing/AuditEventDeath.cs @@ -11,6 +11,9 @@ public class AuditEventDeath : AuditEventBase public AuditEventDeath(Player killer, Player victim, Fleet fleet) { GameTime = fleet?.World.Time ?? 0; + PublicURL = fleet?.World?.GameConfiguration?.PublicURL; + WorldKey = fleet?.World?.WorldKey; + Killer = new AuditModelPlayer(killer); Victim = new AuditModelPlayer(victim); } diff --git a/Game.Engine/Auditing/AuditEventSpawn.cs b/Game.Engine/Auditing/AuditEventSpawn.cs index 8c61205e..c54b6299 100644 --- a/Game.Engine/Auditing/AuditEventSpawn.cs +++ b/Game.Engine/Auditing/AuditEventSpawn.cs @@ -10,6 +10,8 @@ public class AuditEventSpawn : AuditEventBase public AuditEventSpawn(Player player) { GameTime = player?.World?.Time ?? 0; + PublicURL = player?.World?.GameConfiguration?.PublicURL; + WorldKey = player?.World?.WorldKey; Player = new AuditModelPlayer(player); } }