1
0

SharedChatEvents.cs 774 B

123456789101112131415161718192021222324
  1. using Content.Shared.Speech;
  2. using Robust.Shared.Prototypes;
  3. using Content.Shared.Inventory;
  4. namespace Content.Shared.Chat;
  5. /// <summary>
  6. /// This event should be sent everytime an entity talks (Radio, local chat, etc...).
  7. /// The event is sent to both the entity itself, and all clothing (For stuff like voice masks).
  8. /// </summary>
  9. public sealed class TransformSpeakerNameEvent : EntityEventArgs, IInventoryRelayEvent
  10. {
  11. public SlotFlags TargetSlots { get; } = SlotFlags.WITHOUT_POCKET;
  12. public EntityUid Sender;
  13. public string VoiceName;
  14. public ProtoId<SpeechVerbPrototype>? SpeechVerb;
  15. public TransformSpeakerNameEvent(EntityUid sender, string name)
  16. {
  17. Sender = sender;
  18. VoiceName = name;
  19. SpeechVerb = null;
  20. }
  21. }