Remove reference to deleted mind (#14101)

This commit is contained in:
Leon Friedrich
2023-02-14 15:46:44 +13:00
committed by GitHub
parent fb23370938
commit 9c6c6a797a
2 changed files with 4 additions and 0 deletions

View File

@@ -107,6 +107,7 @@ public sealed class MindSystem : EntitySystem
{
// This should be an error, if it didn't cause tests to start erroring when they delete a player.
Logger.WarningS("mind", $"Entity \"{ToPrettyString(uid)}\" for {mind.Mind?.CharacterName} was deleted, and no applicable spawn location is available.");
mind.Mind?.TransferTo(null);
return;
}