From d5d21e70791e028e8fe2d8f9c66c100e5d3a7edb Mon Sep 17 00:00:00 2001 From: Sam Date: Tue, 21 Apr 2020 08:26:53 +1000 Subject: [PATCH] Chat fix (#832) --- Content.Server/Chat/ChatCommands.cs | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/Content.Server/Chat/ChatCommands.cs b/Content.Server/Chat/ChatCommands.cs index 00ca6a4124..8e299b3df5 100644 --- a/Content.Server/Chat/ChatCommands.cs +++ b/Content.Server/Chat/ChatCommands.cs @@ -1,6 +1,6 @@ using Content.Server.GameObjects.Components.Observer; using Content.Server.Interfaces.Chat; -using Content.Server.Observer; +using Content.Server.Players; using Robust.Server.Interfaces.Console; using Robust.Server.Interfaces.Player; using Robust.Shared.Enums; @@ -29,7 +29,11 @@ namespace Content.Server.Chat if (player.AttachedEntity.HasComponent()) chat.SendDeadChat(player, message); else - chat.EntitySay(player.AttachedEntity, message); + { + var mindComponent = player.ContentData().Mind; + chat.EntitySay(mindComponent.OwnedEntity, message); + } + } } @@ -51,14 +55,15 @@ namespace Content.Server.Chat var action = string.Join(" ", args); - chat.EntityMe(player.AttachedEntity, action); + var mindComponent = player.ContentData().Mind; + chat.EntityMe(mindComponent.OwnedEntity, action); } } internal class OOCCommand : IClientCommand { public string Command => "ooc"; - public string Description => "Send Out of Character chat messages."; + public string Description => "Send Out Of Character chat messages."; public string Help => "ooc "; public void Execute(IConsoleShell shell, IPlayerSession player, string[] args)