diff options
| author | Michael VanOverbeek <[email protected]> | 2017-03-09 17:52:24 +0000 |
|---|---|---|
| committer | Michael VanOverbeek <[email protected]> | 2017-03-09 17:52:24 +0000 |
| commit | 23671dedd1b715eb3b24d3174530926d7cbc3b52 (patch) | |
| tree | fe352fc55be071a071d5480116efe12ff19248f8 /ShiftOS.Server | |
| parent | ea430ac9df46cf01c8c4f8502097057a8da42600 (diff) | |
| download | shiftos_thereturn-23671dedd1b715eb3b24d3174530926d7cbc3b52.tar.gz shiftos_thereturn-23671dedd1b715eb3b24d3174530926d7cbc3b52.tar.bz2 shiftos_thereturn-23671dedd1b715eb3b24d3174530926d7cbc3b52.zip | |
MUD now collects diagnostics.
Diffstat (limited to 'ShiftOS.Server')
| -rw-r--r-- | ShiftOS.Server/Core.cs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/ShiftOS.Server/Core.cs b/ShiftOS.Server/Core.cs index a602240..e14ca27 100644 --- a/ShiftOS.Server/Core.cs +++ b/ShiftOS.Server/Core.cs @@ -127,6 +127,17 @@ namespace ShiftOS.Server } + [MudRequest("diag_log", typeof(string))] + public static void Diagnostic(string guid, string line) + { + List<string> lines = new List<string>(); + if (File.Exists("diagnostics.log")) + lines = new List<string>(File.ReadAllLines("diagnostics.log")); + + lines.Add(line); + File.WriteAllLines("diagnostics.log", lines.ToArray()); + } + [MudRequest("getusers", typeof(string))] public static void GetAllUsers(string guid, string contents) { |
