* 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
36 lines
1.1 KiB
C#
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;
|
|
}
|
|
}
|