diff --git a/Content.Server/Spawners/Components/ConditionalSpawnerComponent.cs b/Content.Server/Spawners/Components/ConditionalSpawnerComponent.cs index 1b06367b0d..c6f4871b7e 100644 --- a/Content.Server/Spawners/Components/ConditionalSpawnerComponent.cs +++ b/Content.Server/Spawners/Components/ConditionalSpawnerComponent.cs @@ -6,14 +6,25 @@ namespace Content.Server.Spawners.Components [Virtual] public partial class ConditionalSpawnerComponent : Component { + /// + /// A list of entities, one of which can spawn in after calling Spawn() + /// [ViewVariables(VVAccess.ReadWrite)] [DataField] public List Prototypes { get; set; } = new(); + /// + /// A list of game rules. + /// If at least one of them was launched in the game, + /// an attempt will occur to spawn one of the objects in the Prototypes list + /// [ViewVariables(VVAccess.ReadWrite)] [DataField] public List GameRules = new(); + /// + /// Chance of spawning an entity + /// [ViewVariables(VVAccess.ReadWrite)] [DataField] public float Chance { get; set; } = 1.0f; diff --git a/Content.Server/Spawners/Components/RandomSpawnerComponent.cs b/Content.Server/Spawners/Components/RandomSpawnerComponent.cs index e6a597f365..ec1b3249a9 100644 --- a/Content.Server/Spawners/Components/RandomSpawnerComponent.cs +++ b/Content.Server/Spawners/Components/RandomSpawnerComponent.cs @@ -5,18 +5,33 @@ namespace Content.Server.Spawners.Components [RegisterComponent, EntityCategory("Spawner")] public sealed partial class RandomSpawnerComponent : ConditionalSpawnerComponent { + /// + /// A list of rarer entities that can spawn with the RareChance + /// instead of one of the entities in the Prototypes list. + /// [ViewVariables(VVAccess.ReadWrite)] [DataField] public List RarePrototypes { get; set; } = new(); + /// + /// The chance that a rare prototype may spawn instead of a common prototype + /// [ViewVariables(VVAccess.ReadWrite)] [DataField] public float RareChance { get; set; } = 0.05f; + /// + /// Scatter of entity spawn coordinates + /// [ViewVariables(VVAccess.ReadWrite)] [DataField] public float Offset { get; set; } = 0.2f; + /// + /// A variable meaning whether the spawn will + /// be able to be used again or whether + /// it will be destroyed after the first use + /// [DataField] public bool DeleteSpawnerAfterSpawn = true; }