Files
tbd-station-14/Content.Server/Atmos/Piping/Trinary/Components/PressureControlledValveComponent.cs
Kevin Zheng 9cb7e0f6c4 Make atmos Turing-complete (#10520)
* Add pneumatic valves

Pneumatic valves permit bidirectional flow between the inlet and outlet
if the pressure at the control port is high enough.

* Add construction recipe
2022-08-11 16:19:31 -05:00

36 lines
1.1 KiB
C#

using Content.Shared.Atmos;
namespace Content.Server.Atmos.Piping.Trinary.Components
{
[RegisterComponent]
public sealed class PressureControlledValveComponent : Component
{
[ViewVariables(VVAccess.ReadWrite)]
[DataField("inlet")]
public string InletName { get; set; } = "inlet";
[ViewVariables(VVAccess.ReadWrite)]
[DataField("control")]
public string ControlName { get; set; } = "control";
[ViewVariables(VVAccess.ReadWrite)]
[DataField("outlet")]
public string OutletName { get; set; } = "outlet";
[ViewVariables(VVAccess.ReadOnly)]
[DataField("enabled")]
public bool Enabled { get; set; } = false;
[ViewVariables(VVAccess.ReadWrite)]
[DataField("gain")]
public float Gain { get; set; } = 10;
[ViewVariables(VVAccess.ReadWrite)]
[DataField("threshold")]
public float Threshold { get; set; } = Atmospherics.OneAtmosphere;
[DataField("maxTransferRate")]
public float MaxTransferRate { get; set; } = Atmospherics.MaxTransferRate;
}
}