using Content.Shared.Speech.EntitySystems; using Robust.Shared.Serialization; namespace Content.Shared.Speech.Components; [RegisterComponent] [AutoGenerateComponentState] public sealed partial class MeleeSpeechComponent : Component { [ViewVariables(VVAccess.ReadWrite)] [DataField("Battlecry")] [AutoNetworkedField] public string? Battlecry; [ViewVariables(VVAccess.ReadWrite)] [DataField("MaxBattlecryLength")] public int MaxBattlecryLength = 12; } /// /// Key representing which is currently open. /// Useful when there are multiple UI for an object. Here it's future-proofing only. /// [Serializable, NetSerializable] public enum MeleeSpeechUiKey : byte { Key, } /// /// Represents an state that can be sent to the client /// [Serializable, NetSerializable] public sealed class MeleeSpeechBoundUserInterfaceState : BoundUserInterfaceState { public string CurrentBattlecry { get; } public MeleeSpeechBoundUserInterfaceState(string currentBattlecry) { CurrentBattlecry = currentBattlecry; } } [Serializable, NetSerializable] public sealed class MeleeSpeechBattlecryChangedMessage : BoundUserInterfaceMessage { public string Battlecry { get; } public MeleeSpeechBattlecryChangedMessage(string battlecry) { Battlecry = battlecry; } }