From 21c5bf2c321924f59d567dce4f17ba3c0399b990 Mon Sep 17 00:00:00 2001 From: BIGZi0348 <118811750+BIGZi0348@users.noreply.github.com> Date: Sun, 20 Oct 2024 00:34:25 +0300 Subject: [PATCH] ShowManifestFeature (#738) --- .../GameTicking/Commands/ShowManifestCommand.cs | 12 +++++------- .../RoundEnd/RoundEndSummaryUIController.cs | 9 +++++++++ Resources/keybinds.yml | 2 +- 3 files changed, 15 insertions(+), 8 deletions(-) diff --git a/Content.Client/GameTicking/Commands/ShowManifestCommand.cs b/Content.Client/GameTicking/Commands/ShowManifestCommand.cs index d3f77c8f59..bc1a7097c5 100644 --- a/Content.Client/GameTicking/Commands/ShowManifestCommand.cs +++ b/Content.Client/GameTicking/Commands/ShowManifestCommand.cs @@ -1,23 +1,21 @@ -using Content.Client.GameTicking.Managers; -using Content.Shared.Administration; -using Content.Shared.GameTicking; +using Content.Shared.Administration; using Robust.Shared.Console; -using Robust.Shared.Network; +using Content.Client.RoundEnd; +using Robust.Client.UserInterface; namespace Content.Client.GameTicking.Commands { [AnyCommand] public sealed class ShowManifestCommand : IConsoleCommand { - [Dependency] private readonly IEntitySystemManager _entitySystem = default!; - + [Dependency] private readonly IUserInterfaceManager _userInterfaceManager = default!; public string Command => "showmanifest"; public string Description => "Shows round end summary window"; public string Help => "Usage: showmanifest"; public void Execute(IConsoleShell shell, string argStr, string[] args) { - shell.WriteLine("You can't open manifest right now"); + _userInterfaceManager.GetUIController().ShowManifest(); } } } diff --git a/Content.Client/RoundEnd/RoundEndSummaryUIController.cs b/Content.Client/RoundEnd/RoundEndSummaryUIController.cs index cf824833ef..a323f1641a 100644 --- a/Content.Client/RoundEnd/RoundEndSummaryUIController.cs +++ b/Content.Client/RoundEnd/RoundEndSummaryUIController.cs @@ -48,4 +48,13 @@ public sealed class RoundEndSummaryUIController : UIController, _input.SetInputCommand(ContentKeyFunctions.ToggleRoundEndSummaryWindow, InputCmdHandler.FromDelegate(ToggleScoreboardWindow)); } + + /// + /// WD. + /// Used for cosnole command. + /// + public void ShowManifest() + { + ToggleScoreboardWindow(); + } } diff --git a/Resources/keybinds.yml b/Resources/keybinds.yml index 536a86c935..5626322985 100644 --- a/Resources/keybinds.yml +++ b/Resources/keybinds.yml @@ -458,7 +458,7 @@ binds: - function: OpenDecalSpawnWindow type: State key: F8 -- function: OpenScoreboardWindow +- function: ToggleRoundEndSummaryWindow # WD ahead of wizden upstream type: State key: F9 - function: OpenSandboxWindow