From dfd72c5db2c6f654716a1d033de3856dbfa80857 Mon Sep 17 00:00:00 2001 From: Jacob Tong <10494922+ShadowCommander@users.noreply.github.com> Date: Fri, 28 Oct 2022 19:38:53 -0700 Subject: [PATCH] Fix aghost when aghosting from a ghost (#12252) --- Content.Server/Administration/Commands/AGhost.cs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Content.Server/Administration/Commands/AGhost.cs b/Content.Server/Administration/Commands/AGhost.cs index 15dde5b1ee..037c289cbd 100644 --- a/Content.Server/Administration/Commands/AGhost.cs +++ b/Content.Server/Administration/Commands/AGhost.cs @@ -1,4 +1,4 @@ -using Content.Server.GameTicking; +using Content.Server.GameTicking; using Content.Server.Ghost.Components; using Content.Server.Players; using Content.Shared.Administration; @@ -40,7 +40,8 @@ namespace Content.Server.Administration.Commands return; } - var canReturn = mind.CurrentEntity != null; + var canReturn = mind.CurrentEntity != null + && !_entities.HasComponent(mind.CurrentEntity); var coordinates = player.AttachedEntity != null ? _entities.GetComponent(player.AttachedEntity.Value).Coordinates : EntitySystem.Get().GetObserverSpawnPoint();