Files
wwdpublic/Content.Server/Speech/EntitySystems/UnblockableSpeechSystem.cs
Skye dc4ec07ac1 Borgs can now speak while in Crit (#21802)
* Borgs can speak while crit, also radio bug fix

* Revert "Borgs can speak while crit, also radio bug fix"

This reverts commit e1136ad781229cf5fc3cadcf70742168fc73d961.

* Borgs can speak in crit + radio bug fix

* Tied to a new generic component on SpeechComponent

* Ignoring Speech Block via Component uses an event!

* Remove debug logs and bypass if already true
2023-12-02 20:35:38 +01:00

19 lines
542 B
C#

using Content.Server.Chat.Systems;
using Content.Server.Speech.Components;
namespace Content.Server.Speech.EntitySystems
{
public sealed class UnblockableSpeechSystem : EntitySystem
{
public override void Initialize()
{
SubscribeLocalEvent<UnblockableSpeechComponent, CheckIgnoreSpeechBlockerEvent>(OnCheck);
}
private void OnCheck(EntityUid uid, UnblockableSpeechComponent component, CheckIgnoreSpeechBlockerEvent args)
{
args.IgnoreBlocker = true;
}
}
}