forced collective mind for abductors

This commit is contained in:
SplikZerys 2025-07-08 14:39:43 -04:00
parent a25f97882a
commit 5fda7fe52f
2 changed files with 10 additions and 0 deletions

View file

@ -12,6 +12,7 @@ using Content.Server.Speech.Prototypes;
using Content.Server.Speech.EntitySystems;
using Content.Server.Station.Components;
using Content.Server.Station.Systems;
using Content.Shared._Sunrise.Antags.Abductor;
using Content.Shared._Sunrise.CollectiveMind;
using Content.Shared.ActionBlocker;
using Content.Shared.Administration;
@ -183,6 +184,12 @@ public sealed partial class ChatSystem : SharedChatSystem
bool isFormatted = false //sunrise-edit
)
{
if (TryComp<AbductorComponent>(source, out var comp))
{
_prototypeManager.TryIndex<CollectiveMindPrototype>(comp.AbductorCollectiveMindProto, out var channel);
SendCollectiveMindChat(source, message, channel);
return;
}
if (HasComp<GhostComponent>(source))
{
// Ghosts can only send dead chat messages, so we'll forward it to InGame OOC.

View file

@ -1,3 +1,4 @@
using Content.Shared._Sunrise.CollectiveMind;
using Content.Shared.Actions;
using Content.Shared.Communications;
using Content.Shared.Ninja.Systems;
@ -69,6 +70,8 @@ public sealed partial class AbductorDispencerComponent : Component
[RegisterComponent, NetworkedComponent, Access(typeof(SharedAbductorSystem))]
public sealed partial class AbductorComponent : Component
{
[ValidatePrototypeId<CollectiveMindPrototype>]
public string AbductorCollectiveMindProto = "Abductor";
}
[RegisterComponent, NetworkedComponent, Access(typeof(SharedAbductorSystem)), AutoGenerateComponentState]