Air alarm fixes (again, oops) (#7715)

* fixes critical issue

* alright, this might be the actual fix

* removes useless null checks

* couple more

* removes default functions from unary device data
This commit is contained in:
Flipp Syder
2022-04-22 23:21:00 -07:00
committed by GitHub
parent 669d5a9406
commit 565bfa86a4
8 changed files with 32 additions and 64 deletions

View File

@@ -10,10 +10,10 @@ namespace Content.Shared.Atmos.Piping.Unary.Components
public bool Enabled { get; set; }
public bool Dirty { get; set; }
public bool IgnoreAlarms { get; set; } = false;
public VentPumpDirection? PumpDirection { get; set; }
public VentPressureBound? PressureChecks { get; set; }
public float? ExternalPressureBound { get; set; }
public float? InternalPressureBound { get; set; }
public VentPumpDirection PumpDirection { get; set; } = VentPumpDirection.Releasing;
public VentPressureBound PressureChecks { get; set; } = VentPressureBound.ExternalBound;
public float ExternalPressureBound { get; set; } = Atmospherics.OneAtmosphere;
public float InternalPressureBound { get; set; } = 0f;
// Presets for 'dumb' air alarm modes
@@ -45,18 +45,6 @@ namespace Content.Shared.Atmos.Piping.Unary.Components
ExternalPressureBound = Atmospherics.OneAtmosphere,
InternalPressureBound = 0f
};
public static GasVentPumpData Default()
{
return new GasVentPumpData
{
Enabled = true,
PumpDirection = VentPumpDirection.Releasing,
PressureChecks = VentPressureBound.ExternalBound,
ExternalPressureBound = Atmospherics.OneAtmosphere,
InternalPressureBound = 0f
};
}
}
[Serializable, NetSerializable]