Limit atmos device rates (#6533)

This commit is contained in:
Leon Friedrich
2022-03-01 03:39:30 +13:00
committed by GitHub
parent ffed5eec81
commit ee7d0440f3
20 changed files with 220 additions and 116 deletions

View File

@@ -173,7 +173,7 @@ namespace Content.Server.Atmos.Piping.Trinary.EntitySystems
private void OnOutputPressureChangeMessage(EntityUid uid, GasMixerComponent mixer, GasMixerChangeOutputPressureMessage args)
{
mixer.TargetPressure = Math.Clamp(args.Pressure, 0f, Atmospherics.MaxOutputPressure);
mixer.TargetPressure = Math.Clamp(args.Pressure, 0f, mixer.MaxTargetPressure);
_adminLogSystem.Add(LogType.AtmosPressureChanged, LogImpact.Medium,
$"{ToPrettyString(args.Session.AttachedEntity!.Value):player} set the pressure on {ToPrettyString(uid):device} to {args.Pressure}kPa");
DirtyUI(uid, mixer);