using Content.Shared.Doors.Systems; using Content.Shared.Whitelist; using Robust.Shared.Audio; using Robust.Shared.GameStates; using Robust.Shared.Serialization; using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom; namespace Content.Shared.Doors.Components; /// /// This is used for a condition door that allows entry only through a single side. /// [RegisterComponent, NetworkedComponent, AutoGenerateComponentState, AutoGenerateComponentPause] [Access(typeof(SharedTurnstileSystem))] public sealed partial class TurnstileComponent : Component { /// /// A whitelist of the things this turnstile can choose to block or let through. /// Things not in this whitelist will be ignored by default. /// [DataField] public EntityWhitelist? ProcessWhitelist; /// /// The next time at which the resist message can show. /// [DataField(customTypeSerializer: typeof(TimeOffsetSerializer)), AutoNetworkedField, AutoPausedField] public TimeSpan NextResistTime; /// /// Maintained hashset of entities currently passing through the turnstile. /// [DataField, AutoNetworkedField] public HashSet CollideExceptions = new(); /// /// default state of the turnstile sprite. /// [DataField] public string DefaultState = "turnstile"; /// /// animation state of the turnstile spinning. /// [DataField] public string SpinState = "operate"; /// /// animation state of the turnstile denying entry. /// [DataField] public string DenyState = "deny"; /// /// Sound to play when the turnstile admits a mob through. /// [DataField] public SoundSpecifier? TurnSound = new SoundPathSpecifier("/Audio/Items/ratchet.ogg", AudioParams.Default.WithVolume(-6)); /// /// Sound to play when the turnstile denies entry /// [DataField] public SoundSpecifier? DenySound = new SoundPathSpecifier("/Audio/Machines/airlock_deny.ogg") { Params = new() { Volume = -7, }, }; } [Serializable, NetSerializable] public enum TurnstileVisualLayers : byte { Base }