using Robust.Shared.Audio; using Robust.Shared.GameStates; namespace Content.Shared.Weapons.Misc; [RegisterComponent, NetworkedComponent, AutoGenerateComponentState] public sealed partial class TetherGunComponent : Component { [ViewVariables(VVAccess.ReadWrite), DataField("maxDistance"), AutoNetworkedField] public float MaxDistance = 10f; /// /// The entity the tethered target has a joint to. /// [DataField("tetherEntity"), AutoNetworkedField] public EntityUid? TetherEntity; /// /// The entity currently tethered. /// [ViewVariables(VVAccess.ReadWrite), DataField("tethered"), AutoNetworkedField] public EntityUid? Tethered; /// /// Can the tethergun unanchor entities. /// [ViewVariables(VVAccess.ReadWrite), DataField("canUnanchor"), AutoNetworkedField] public bool CanUnanchor = false; [ViewVariables(VVAccess.ReadWrite), DataField("canTetherAlive"), AutoNetworkedField] public bool CanTetherAlive = false; /// /// Max force between the tether entity and the tethered target. /// [ViewVariables(VVAccess.ReadWrite), DataField("maxForce"), AutoNetworkedField] public float MaxForce = 200f; [ViewVariables(VVAccess.ReadWrite), DataField("frequency"), AutoNetworkedField] public float Frequency = 10f; [ViewVariables(VVAccess.ReadWrite), DataField("dampingRatio"), AutoNetworkedField] public float DampingRatio = 2f; /// /// Maximum amount of mass a tethered entity can have. /// [ViewVariables(VVAccess.ReadWrite), DataField("massLimit"), AutoNetworkedField] public float MassLimit = 100f; [ViewVariables(VVAccess.ReadWrite), DataField("sound"), AutoNetworkedField] public SoundSpecifier? Sound = new SoundPathSpecifier("/Audio/Weapons/weoweo.ogg") { Params = AudioParams.Default.WithLoop(true).WithVolume(-8f), }; public IPlayingAudioStream? Stream; }