* Component for clothes to suppress scream noise GaggedComponent + AddGaggedClothingComponent and relevant systems to make them work. Currently only stifles the scream _action_, not all emotes because if a mime can silently emote, so can gagged you! * fix comments * swap to inventory relay and make it more general such that specific emotes or emotes of a given category can be blocked * power gloves shouldn't block snapping * easy fixes * blockable emote event * pr comments, switch to using emote event mostly * pr comments add beforeEmoteEvent add emote blocker name to popup maybe some other stuff, I forget * get rid of emoteevent's source because I don't need it anymore * smol clean * formatting, style, and one minor thing where having a muzzle in your pocket would gag you
25 lines
734 B
C#
25 lines
734 B
C#
using Content.Shared.Chat.Prototypes;
|
|
using Robust.Shared.Prototypes;
|
|
|
|
namespace Content.Server.Speech.Components;
|
|
|
|
/// <summary>
|
|
/// Suppresses emotes with the given categories or ID.
|
|
/// Additionally, if the Scream Emote would be blocked, also blocks the Scream Action.
|
|
/// </summary>
|
|
[RegisterComponent]
|
|
public sealed partial class EmoteBlockerComponent : Component
|
|
{
|
|
/// <summary>
|
|
/// Which categories of emotes are blocked by this component.
|
|
/// </summary>
|
|
[DataField]
|
|
public HashSet<EmoteCategory> BlocksCategories = [];
|
|
|
|
/// <summary>
|
|
/// IDs of which specific emotes are blocked by this component.
|
|
/// </summary>
|
|
[DataField]
|
|
public HashSet<ProtoId<EmotePrototype>> BlocksEmotes = [];
|
|
}
|