Fixes server shutdown crash & client error log spam. (#67)
This commit is contained in:
committed by
GitHub
parent
2d9285f790
commit
205a4fc530
@@ -27,6 +27,13 @@ namespace Content.Client.GameObjects
|
||||
private string TemplateName = "HumanInventory"; //stored for serialization purposes
|
||||
public event EventHandler<BoundKeyChangedMessage> OnCharacterMenuKey;
|
||||
|
||||
public override void OnRemove()
|
||||
{
|
||||
base.OnRemove();
|
||||
|
||||
Window.Dispose();
|
||||
}
|
||||
|
||||
public override void ExposeData(EntitySerializer serializer)
|
||||
{
|
||||
base.ExposeData(serializer);
|
||||
|
||||
@@ -13,6 +13,7 @@ using SS14.Shared.IoC;
|
||||
using SS14.Server.Interfaces.Player;
|
||||
using SS14.Shared.GameObjects.Serialization;
|
||||
using SS14.Shared.ContentPack;
|
||||
using System.Linq;
|
||||
|
||||
namespace Content.Server.GameObjects
|
||||
{
|
||||
@@ -44,7 +45,8 @@ namespace Content.Server.GameObjects
|
||||
|
||||
public override void OnRemove()
|
||||
{
|
||||
foreach (var slot in SlotContainers.Keys)
|
||||
var slots = SlotContainers.Keys.ToList();
|
||||
foreach (var slot in slots)
|
||||
{
|
||||
RemoveSlot(slot);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user