diff --git a/Content.Client/ADT/CollectiveMind/Systems/CollectiveMindSystem.cs b/Content.Client/ADT/CollectiveMind/Systems/CollectiveMindSystem.cs new file mode 100644 index 00000000000..5949eac6cc2 --- /dev/null +++ b/Content.Client/ADT/CollectiveMind/Systems/CollectiveMindSystem.cs @@ -0,0 +1,31 @@ +using Content.Client.Chat.Managers; +using Content.Shared.Sirena.CollectiveMind; +using Robust.Client.Player; + +namespace Content.Client.Sirena.CollectiveMind; + +public sealed class CollectiveMindSystem : EntitySystem +{ + [Dependency] private readonly IChatManager _chatManager = default!; + [Dependency] private readonly IPlayerManager _playerManager = default!; + + public override void Initialize() + { + base.Initialize(); + SubscribeLocalEvent(OnInit); + SubscribeLocalEvent(OnRemove); + } + + public CollectiveMindComponent? Player => CompOrNull(_playerManager.LocalPlayer?.ControlledEntity); + public bool IsCollectiveMind => Player != null; + + private void OnInit(EntityUid uid, CollectiveMindComponent component, ComponentInit args) + { + _chatManager.UpdatePermissions(); + } + + private void OnRemove(EntityUid uid, CollectiveMindComponent component, ComponentRemove args) + { + _chatManager.UpdatePermissions(); + } +} diff --git a/Content.Client/ADT/UserInterface/Systems/Ghost/Controls/GhostBarRulesWindow.xaml b/Content.Client/ADT/UserInterface/Systems/Ghost/Controls/GhostBarRulesWindow.xaml new file mode 100644 index 00000000000..e0e79c2e83e --- /dev/null +++ b/Content.Client/ADT/UserInterface/Systems/Ghost/Controls/GhostBarRulesWindow.xaml @@ -0,0 +1,15 @@ + + + +