Removing TSPlayer.user from heapshot
This commit is contained in:
parent
7f9e41e7ab
commit
ac531a7d14
1 changed files with 10 additions and 0 deletions
|
|
@ -176,6 +176,8 @@ namespace TShockAPI
|
||||||
string logFilename;
|
string logFilename;
|
||||||
string logPathSetupWarning;
|
string logPathSetupWarning;
|
||||||
|
|
||||||
|
TerrariaApi.Reporting.CrashReporter.HeapshotRequesting += CrashReporter_HeapshotRequesting;
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
HandleCommandLine(Environment.GetCommandLineArgs());
|
HandleCommandLine(Environment.GetCommandLineArgs());
|
||||||
|
|
@ -339,6 +341,14 @@ namespace TShockAPI
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected void CrashReporter_HeapshotRequesting(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
foreach (TSPlayer player in TShock.Players)
|
||||||
|
{
|
||||||
|
player.User = null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>Dispose - Called when disposing.</summary>
|
/// <summary>Dispose - Called when disposing.</summary>
|
||||||
/// <param name="disposing">disposing - If set, disposes of all hooks and other systems.</param>
|
/// <param name="disposing">disposing - If set, disposes of all hooks and other systems.</param>
|
||||||
protected override void Dispose(bool disposing)
|
protected override void Dispose(bool disposing)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue