using Robust.Shared.GameStates; using Robust.Shared.Prototypes; namespace Content.Shared.Trigger.Components.Effects; /// /// Adds or removes the specified components when triggered. /// If TargetUser is true they will be added to or removed from the user instead. /// [RegisterComponent, NetworkedComponent, AutoGenerateComponentState] public sealed partial class ToggleComponentsOnTriggerComponent : BaseXOnTriggerComponent { /// /// The list of components that will be added/removed. /// [DataField(required: true)] public ComponentRegistry Components = new(); /// /// Are the components currently added? /// [DataField, AutoNetworkedField] public bool ComponentsAdded; /// /// Should components that already exist on the entity be overwritten? /// (They will still be removed when toggling again). /// [DataField, AutoNetworkedField] public bool RemoveExisting = false; }