From 7995817c8029098617d8b70ca1a6ed22c3b30ac3 Mon Sep 17 00:00:00 2001 From: Kara Date: Sat, 18 Mar 2023 17:56:38 -0700 Subject: [PATCH] Entity storage air capacity changes (#14734) --- Content.Server/Storage/Components/EntityStorageComponent.cs | 3 ++- Content.Server/Storage/EntitySystems/EntityStorageSystem.cs | 2 +- .../Storage/Components/SharedEntityStorageComponent.cs | 1 - .../Prototypes/Entities/Structures/Storage/Crates/crates.yml | 3 +++ 4 files changed, 6 insertions(+), 3 deletions(-) diff --git a/Content.Server/Storage/Components/EntityStorageComponent.cs b/Content.Server/Storage/Components/EntityStorageComponent.cs index 568c67bc06..0824dc8909 100644 --- a/Content.Server/Storage/Components/EntityStorageComponent.cs +++ b/Content.Server/Storage/Components/EntityStorageComponent.cs @@ -12,5 +12,6 @@ public sealed class EntityStorageComponent : SharedEntityStorageComponent, IGasM /// None while open. Grabs gas from the atmosphere when closed, and exposes any entities inside to it. /// [ViewVariables(VVAccess.ReadWrite)] - public GasMixture Air { get; set; } = new (GasMixVolume); + [DataField("air")] + public GasMixture Air { get; set; } = new (200); } diff --git a/Content.Server/Storage/EntitySystems/EntityStorageSystem.cs b/Content.Server/Storage/EntitySystems/EntityStorageSystem.cs index ebefd304f7..46459105bf 100644 --- a/Content.Server/Storage/EntitySystems/EntityStorageSystem.cs +++ b/Content.Server/Storage/EntitySystems/EntityStorageSystem.cs @@ -77,7 +77,7 @@ public sealed class EntityStorageSystem : SharedEntityStorageSystem if (tile != null && _atmos.GetTileMixture(tile.Value.GridUid, null, tile.Value.GridIndices, true) is {} environment) { - _atmos.Merge(serverComp.Air, environment.RemoveVolume(SharedEntityStorageComponent.GasMixVolume)); + _atmos.Merge(serverComp.Air, environment.RemoveVolume(serverComp.Air.Volume)); } } diff --git a/Content.Shared/Storage/Components/SharedEntityStorageComponent.cs b/Content.Shared/Storage/Components/SharedEntityStorageComponent.cs index bbabde8e7d..9f6b9413a0 100644 --- a/Content.Shared/Storage/Components/SharedEntityStorageComponent.cs +++ b/Content.Shared/Storage/Components/SharedEntityStorageComponent.cs @@ -11,7 +11,6 @@ namespace Content.Shared.Storage.Components; public abstract class SharedEntityStorageComponent : Component { public readonly float MaxSize = 1.0f; // maximum width or height of an entity allowed inside the storage. - public const float GasMixVolume = 70f; public static readonly TimeSpan InternalOpenAttemptDelay = TimeSpan.FromSeconds(0.5); public TimeSpan LastInternalOpenAttempt; diff --git a/Resources/Prototypes/Entities/Structures/Storage/Crates/crates.yml b/Resources/Prototypes/Entities/Structures/Storage/Crates/crates.yml index 0f3bfb795d..381dbe962b 100644 --- a/Resources/Prototypes/Entities/Structures/Storage/Crates/crates.yml +++ b/Resources/Prototypes/Entities/Structures/Storage/Crates/crates.yml @@ -240,6 +240,9 @@ id: CrateLivestock name: livestock crate components: + - type: EntityStorage + air: + volume: 800 - type: Sprite sprite: Structures/Storage/Crates/livestock.rsi layers: -- 2.52.0