Command resolves and LEC conversions batch 4 (#38382)

* reeeecolllaaaaaaaa

* gonna convert these to public while I'm here for consistency sake

* requested changes.
This commit is contained in:
Kyle Tyo
2025-06-18 20:03:28 -04:00
committed by GitHub
parent d36a45a57f
commit ca72ca1464
18 changed files with 104 additions and 102 deletions

View File

@@ -5,17 +5,17 @@ using Robust.Shared.Console;
namespace Content.Server.Chat.Commands
{
[AnyCommand]
internal sealed class OOCCommand : IConsoleCommand
internal sealed class OOCCommand : LocalizedCommands
{
public string Command => "ooc";
public string Description => "Send Out Of Character chat messages.";
public string Help => "ooc <text>";
[Dependency] private readonly IChatManager _chatManager = default!;
public void Execute(IConsoleShell shell, string argStr, string[] args)
public override string Command => "ooc";
public override void Execute(IConsoleShell shell, string argStr, string[] args)
{
if (shell.Player is not { } player)
{
shell.WriteError("This command cannot be run from the server.");
shell.WriteError(Loc.GetString($"shell-cannot-run-command-from-server"));
return;
}
@@ -26,7 +26,7 @@ namespace Content.Server.Chat.Commands
if (string.IsNullOrEmpty(message))
return;
IoCManager.Resolve<IChatManager>().TrySendOOCMessage(player, message, OOCChatType.OOC);
_chatManager.TrySendOOCMessage(player, message, OOCChatType.OOC);
}
}
}