using Content.Server.Explosion.EntitySystems; using Robust.Shared.Containers; using Robust.Shared.Prototypes; using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom.Prototype; namespace Content.Server.Explosion.Components { [RegisterComponent, Access(typeof(ClusterGrenadeSystem))] public sealed class ClusterGrenadeComponent : Component { public Container GrenadesContainer = default!; /// /// What we fill our prototype with if we want to pre-spawn with grenades. /// [ViewVariables] [DataField("fillPrototype", customTypeSerializer:typeof(PrototypeIdSerializer))] public string? FillPrototype; /// /// If we have a pre-fill how many more can we spawn. /// public int UnspawnedCount; /// /// Maximum grenades in the container. /// [ViewVariables] [DataField("maxGrenadesCount")] public int MaxGrenades = 3; /// /// How long until our grenades are shot out and armed. /// [ViewVariables(VVAccess.ReadWrite)] [DataField("delay")] public float Delay = 1; /// /// Max distance grenades can be thrown. /// [ViewVariables(VVAccess.ReadWrite)] [DataField("distance")] public float ThrowDistance = 50; /// /// This is the end. /// public bool CountDown; } }