diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 4c5dd7694051fd..179b7e45d894ed 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -2,49 +2,30 @@ # Sorting by path instead of by who added it one day :( # this isn't how codeowners rules work pls read the first comment instead of trying to force a sorting order -/Resources/ConfigPresets/WizardsDen/ @Chief-Engineer -# Moony's Gargantuan List Of Things She Cares About, or MGLOTSCA for short. -# You need to add your name to these entries, not make a new one, if you care about them. -/Content.*/Toolshed/ @moonheart08 -**/Toolshed/** @moonheart08 -*Command.cs @moonheart08 -/Content.*/Administration/ @moonheart08 @DrSmugleaf @Chief-Engineer -/Content.*/Station/ @moonheart08 -/Content.*/Maps/ @moonheart08 -/Content.*/GameTicking/ @moonheart08 @EmoGarbage404 -/Resources/ServerInfo/ @moonheart08 @Chief-Engineer -/Resources/ServerInfo/Guidebook/ @moonheart08 @EmoGarbage404 -/Resources/ServerInfo/Guidebook/ServerRules/ @Chief-Engineer -/Resources/engineCommandPerms.yml @moonheart08 @Chief-Engineer -/Resources/clientCommandPerms.yml @moonheart08 @Chief-Engineer +/Resources/ConfigPresets/WizardsDen/ @nikthechampiongr +/Content.*/Administration/ @DrSmugleaf @nikthechampiongr +/Resources/ServerInfo/ @nikthechampiongr +/Resources/ServerInfo/Guidebook/ServerRules/ @nikthechampiongr /Resources/Prototypes/Maps/** @Emisse /Resources/Prototypes/Body/ @DrSmugleaf # suffering /Resources/Prototypes/Entities/Mobs/Player/ @DrSmugleaf /Resources/Prototypes/Entities/Mobs/Species/ @DrSmugleaf -/Resources/Prototypes/Guidebook/rules.yml @Chief-Engineer +/Resources/Prototypes/Guidebook/rules.yml @nikthechampiongr /Content.*/Body/ @DrSmugleaf /Content.YAMLLinter @DrSmugleaf /Content.Shared/Damage/ @DrSmugleaf -/Content.*/Anomaly/ @EmoGarbage404 @TheShuEd -/Content.*/Lathe/ @EmoGarbage404 -/Content.*/Materials/ @EmoGarbage404 -/Content.*/Mech/ @EmoGarbage404 -/Content.*/Research/ @EmoGarbage404 -/Content.*/Stack/ @EmoGarbage404 -/Content.*/Xenoarchaeology/ @EmoGarbage404 -/Content.*/Zombies/ @EmoGarbage404 -/Resources/Prototypes/Entities/Structures/Specific/anomalies.yml @EmoGarbage404 @TheShuEd -/Resources/Prototypes/Research/ @EmoGarbage404 +/Content.*/Anomaly/ @TheShuEd +/Resources/Prototypes/Entities/Structures/Specific/anomalies.yml @TheShuEd /Content.*/Forensics/ @ficcialfaint # SKREEEE /Content.*.Database/ @PJB3005 @DrSmugleaf -/Content.Shared.Database/Log*.cs @PJB3005 @DrSmugleaf @Chief-Engineer +/Content.Shared.Database/Log*.cs @PJB3005 @DrSmugleaf @nikthechampiongr /Pow3r/ @PJB3005 /Content.Server/Power/Pow3r/ @PJB3005 @@ -52,7 +33,7 @@ /Content.*/Atmos/ @Partmedia /Content.*/Botany/ @Partmedia -#Jezi +# Jezi /Content.*/Medical @Jezithyr /Content.*/Body @Jezithyr diff --git a/.github/labeler.yml b/.github/labeler.yml index 69b2ca87749c6e..ca5aeed1f3ca14 100644 --- a/.github/labeler.yml +++ b/.github/labeler.yml @@ -16,6 +16,10 @@ - changed-files: - any-glob-to-any-file: '**/*.swsl' +"Changes: Audio": +- changed-files: + - any-glob-to-any-file: '**/*.ogg' + "Changes: No C#": - changed-files: # Equiv to any-glob-to-all as long as this has one matcher. If ALL changed files are not C# files, then apply label. diff --git a/.github/workflows/build-map-renderer.yml b/.github/workflows/build-map-renderer.yml index 35aed1a7f7f500..398baddd843f26 100644 --- a/.github/workflows/build-map-renderer.yml +++ b/.github/workflows/build-map-renderer.yml @@ -2,11 +2,11 @@ on: push: - branches: [ master, staging, trying ] + branches: [ master, staging, stable ] merge_group: pull_request: types: [ opened, reopened, synchronize, ready_for_review ] - branches: [ master ] + branches: [ master, staging, stable ] jobs: build: diff --git a/.github/workflows/build-test-debug.yml b/.github/workflows/build-test-debug.yml index 47f9fd1a514e62..8f50c621d82ad8 100644 --- a/.github/workflows/build-test-debug.yml +++ b/.github/workflows/build-test-debug.yml @@ -2,11 +2,11 @@ name: Build & Test Debug on: push: - branches: [ master, staging, trying ] + branches: [ master, staging, stable ] merge_group: pull_request: types: [ opened, reopened, synchronize, ready_for_review ] - branches: [ master ] + branches: [ master, staging, stable ] jobs: build: diff --git a/.github/workflows/labeler-size.yml b/.github/workflows/labeler-size.yml index ad6e35c829291a..50f89c9bc870f0 100644 --- a/.github/workflows/labeler-size.yml +++ b/.github/workflows/labeler-size.yml @@ -14,7 +14,7 @@ jobs: { "0": "XS", "10": "S", - "30": "M", - "100": "L", - "1000": "XL" + "100": "M", + "1000": "L", + "5000": "XL" } diff --git a/.github/workflows/test-packaging.yml b/.github/workflows/test-packaging.yml index 2d002f869a169d..bddacb9fa4e5d3 100644 --- a/.github/workflows/test-packaging.yml +++ b/.github/workflows/test-packaging.yml @@ -2,7 +2,7 @@ on: push: - branches: [ master, staging, trying ] + branches: [ master, staging, stable ] paths: - '**.cs' - '**.csproj' @@ -16,7 +16,7 @@ on: merge_group: pull_request: types: [ opened, reopened, synchronize, ready_for_review ] - branches: [ master ] + branches: [ master, staging, stable ] paths: - '**.cs' - '**.csproj' diff --git a/.github/workflows/validate-rgas.yml b/.github/workflows/validate-rgas.yml index 2c4bb40fdf35e0..25191958a8c3ac 100644 --- a/.github/workflows/validate-rgas.yml +++ b/.github/workflows/validate-rgas.yml @@ -1,7 +1,7 @@ name: RGA schema validator on: push: - branches: [ master, staging, trying ] + branches: [ master, staging, stable ] merge_group: pull_request: types: [ opened, reopened, synchronize, ready_for_review ] diff --git a/.github/workflows/validate-rsis.yml b/.github/workflows/validate-rsis.yml index b76df28e6afff0..5d30944c73f6eb 100644 --- a/.github/workflows/validate-rsis.yml +++ b/.github/workflows/validate-rsis.yml @@ -2,7 +2,7 @@ name: RSI Validator on: push: - branches: [ staging, trying ] + branches: [ master, staging, stable ] merge_group: pull_request: paths: diff --git a/.github/workflows/validate_mapfiles.yml b/.github/workflows/validate_mapfiles.yml index fb11e1a4697d88..aaf1edcc289572 100644 --- a/.github/workflows/validate_mapfiles.yml +++ b/.github/workflows/validate_mapfiles.yml @@ -1,7 +1,7 @@ name: Map file schema validator on: push: - branches: [ master, staging, trying ] + branches: [ master, staging, stable ] merge_group: pull_request: types: [ opened, reopened, synchronize, ready_for_review ] diff --git a/.github/workflows/yaml-linter.yml b/.github/workflows/yaml-linter.yml index 691eb29f1de426..0b6e934cb594fd 100644 --- a/.github/workflows/yaml-linter.yml +++ b/.github/workflows/yaml-linter.yml @@ -2,7 +2,7 @@ name: YAML Linter on: push: - branches: [ master, staging, trying ] + branches: [ master, staging, stable ] merge_group: pull_request: types: [ opened, reopened, synchronize, ready_for_review ] diff --git a/Content.Client/Atmos/Consoles/AtmosAlarmEntryContainer.xaml.cs b/Content.Client/Atmos/Consoles/AtmosAlarmEntryContainer.xaml.cs index d663aa0f2ffbf1..f0e4b13356c352 100644 --- a/Content.Client/Atmos/Consoles/AtmosAlarmEntryContainer.xaml.cs +++ b/Content.Client/Atmos/Consoles/AtmosAlarmEntryContainer.xaml.cs @@ -149,12 +149,12 @@ public void UpdateEntry(AtmosAlertsComputerEntry entry, bool isFocus, AtmosAlert foreach ((var gas, (var mol, var percent, var alert)) in keyValuePairs) { FixedPoint2 gasPercent = percent * 100f; - var gasAbbreviation = Atmospherics.GasAbbreviations.GetValueOrDefault(gas, Loc.GetString("gas-unknown-abbreviation")); var gasLabel = new Label() { - Text = Loc.GetString("atmos-alerts-window-other-gases-value", ("shorthand", gasAbbreviation), ("value", gasPercent)), FontOverride = normalFont, + Text = Loc.GetString("atmos-alerts-window-other-gases-value", ("shorthand", gasAbbreviation), ("value", gasPercent)), + FontOverride = normalFont, FontColorOverride = GetAlarmStateColor(alert), HorizontalAlignment = HAlignment.Center, VerticalAlignment = VAlignment.Center, diff --git a/Content.Client/Atmos/Consoles/AtmosMonitoringEntryContainer.xaml b/Content.Client/Atmos/Consoles/AtmosMonitoringEntryContainer.xaml index 781bbd6f08be0c..c742ae7ab31456 100644 --- a/Content.Client/Atmos/Consoles/AtmosMonitoringEntryContainer.xaml +++ b/Content.Client/Atmos/Consoles/AtmosMonitoringEntryContainer.xaml @@ -67,7 +67,6 @@ - diff --git a/Content.Client/Atmos/EntitySystems/GasPressurePumpSystem.cs b/Content.Client/Atmos/EntitySystems/GasPressurePumpSystem.cs new file mode 100644 index 00000000000000..54e16bc86216c5 --- /dev/null +++ b/Content.Client/Atmos/EntitySystems/GasPressurePumpSystem.cs @@ -0,0 +1,23 @@ +using Content.Client.Atmos.UI; +using Content.Shared.Atmos.Components; +using Content.Shared.Atmos.EntitySystems; +using Content.Shared.Atmos.Piping.Binary.Components; + +namespace Content.Client.Atmos.EntitySystems; + +public sealed class GasPressurePumpSystem : SharedGasPressurePumpSystem +{ + public override void Initialize() + { + base.Initialize(); + SubscribeLocalEvent(OnPumpUpdate); + } + + private void OnPumpUpdate(Entity ent, ref AfterAutoHandleStateEvent args) + { + if (UserInterfaceSystem.TryGetOpenUi(ent.Owner, GasPressurePumpUiKey.Key, out var bui)) + { + bui.Update(); + } + } +} diff --git a/Content.Client/Atmos/UI/GasPressurePumpBoundUserInterface.cs b/Content.Client/Atmos/UI/GasPressurePumpBoundUserInterface.cs index 220fdbe875c929..0c07eec4025c35 100644 --- a/Content.Client/Atmos/UI/GasPressurePumpBoundUserInterface.cs +++ b/Content.Client/Atmos/UI/GasPressurePumpBoundUserInterface.cs @@ -1,65 +1,63 @@ using Content.Shared.Atmos; +using Content.Shared.Atmos.Components; using Content.Shared.Atmos.Piping.Binary.Components; +using Content.Shared.IdentityManagement; using Content.Shared.Localizations; using JetBrains.Annotations; -using Robust.Client.GameObjects; using Robust.Client.UserInterface; -namespace Content.Client.Atmos.UI +namespace Content.Client.Atmos.UI; + +/// +/// Initializes a and updates it when new server messages are received. +/// +[UsedImplicitly] +public sealed class GasPressurePumpBoundUserInterface : BoundUserInterface { - /// - /// Initializes a and updates it when new server messages are received. - /// - [UsedImplicitly] - public sealed class GasPressurePumpBoundUserInterface : BoundUserInterface - { - [ViewVariables] - private const float MaxPressure = Atmospherics.MaxOutputPressure; + [ViewVariables] + private const float MaxPressure = Atmospherics.MaxOutputPressure; + + [ViewVariables] + private GasPressurePumpWindow? _window; - [ViewVariables] - private GasPressurePumpWindow? _window; + public GasPressurePumpBoundUserInterface(EntityUid owner, Enum uiKey) : base(owner, uiKey) + { + } - public GasPressurePumpBoundUserInterface(EntityUid owner, Enum uiKey) : base(owner, uiKey) - { - } + protected override void Open() + { + base.Open(); - protected override void Open() - { - base.Open(); + _window = this.CreateWindow(); - _window = this.CreateWindow(); + _window.ToggleStatusButtonPressed += OnToggleStatusButtonPressed; + _window.PumpOutputPressureChanged += OnPumpOutputPressurePressed; + Update(); + } - _window.ToggleStatusButtonPressed += OnToggleStatusButtonPressed; - _window.PumpOutputPressureChanged += OnPumpOutputPressurePressed; - } + public void Update() + { + if (_window == null) + return; - private void OnToggleStatusButtonPressed() - { - if (_window is null) return; - SendMessage(new GasPressurePumpToggleStatusMessage(_window.PumpStatus)); - } + _window.Title = Identity.Name(Owner, EntMan); - private void OnPumpOutputPressurePressed(string value) - { - var pressure = UserInputParser.TryFloat(value, out var parsed) ? parsed : 0f; - if (pressure > MaxPressure) pressure = MaxPressure; + if (!EntMan.TryGetComponent(Owner, out GasPressurePumpComponent? pump)) + return; - SendMessage(new GasPressurePumpChangeOutputPressureMessage(pressure)); - } + _window.SetPumpStatus(pump.Enabled); + _window.MaxPressure = pump.MaxTargetPressure; + _window.SetOutputPressure(pump.TargetPressure); + } - /// - /// Update the UI state based on server-sent info - /// - /// - protected override void UpdateState(BoundUserInterfaceState state) - { - base.UpdateState(state); - if (_window == null || state is not GasPressurePumpBoundUserInterfaceState cast) - return; + private void OnToggleStatusButtonPressed() + { + if (_window is null) return; + SendPredictedMessage(new GasPressurePumpToggleStatusMessage(_window.PumpStatus)); + } - _window.Title = (cast.PumpLabel); - _window.SetPumpStatus(cast.Enabled); - _window.SetOutputPressure(cast.OutputPressure); - } + private void OnPumpOutputPressurePressed(float value) + { + SendPredictedMessage(new GasPressurePumpChangeOutputPressureMessage(value)); } } diff --git a/Content.Client/Atmos/UI/GasPressurePumpWindow.xaml b/Content.Client/Atmos/UI/GasPressurePumpWindow.xaml index a0896a7b41e7b7..f2c2c7cec50862 100644 --- a/Content.Client/Atmos/UI/GasPressurePumpWindow.xaml +++ b/Content.Client/Atmos/UI/GasPressurePumpWindow.xaml @@ -1,22 +1,18 @@ - + xmlns:controls="clr-namespace:Content.Client.UserInterface.Controls" + SetSize="340 110" MinSize="340 110" Title="Pressure Pump"> -