Skip to content
This repository was archived by the owner on Dec 23, 2025. It is now read-only.

Commit 6d64942

Browse files
committed
2 parents 11cc294 + 5c3b613 commit 6d64942

752 files changed

Lines changed: 66824 additions & 40043 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/publish-testing.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
concurrency:
44
group: publish-testing
5+
cancel-in-progress: true
56

67
on:
78
workflow_dispatch:

.github/workflows/publish.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ name: Publish
22

33
concurrency:
44
group: publish
5+
cancel-in-progress: true
56

67
on:
78
workflow_dispatch:
@@ -48,12 +49,14 @@ jobs:
4849
GITHUB_REPOSITORY: ${{ vars.GITHUB_REPOSITORY }}
4950

5051
- name: Publish changelog (Discord)
52+
continue-on-error: true
5153
run: Tools/actions_changelogs_since_last_run.py
5254
env:
5355
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
5456
DISCORD_WEBHOOK_URL: ${{ secrets.CHANGELOG_DISCORD_WEBHOOK }}
5557

5658
- name: Publish changelog (RSS)
59+
continue-on-error: true
5760
run: Tools/actions_changelog_rss.py
5861
env:
5962
CHANGELOG_RSS_KEY: ${{ secrets.CHANGELOG_RSS_KEY }}

Content.Client/Alerts/ClientAlertsSystem.cs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
using Content.Shared.Alert;
33
using JetBrains.Annotations;
44
using Robust.Client.Player;
5+
using Robust.Client.UserInterface;
56
using Robust.Shared.GameStates;
67
using Robust.Shared.Player;
78
using Robust.Shared.Prototypes;
@@ -15,6 +16,7 @@ public sealed class ClientAlertsSystem : AlertsSystem
1516

1617
[Dependency] private readonly IPlayerManager _playerManager = default!;
1718
[Dependency] private readonly IPrototypeManager _prototypeManager = default!;
19+
[Dependency] private readonly IUserInterfaceManager _ui = default!;
1820

1921
public event EventHandler? ClearAlerts;
2022
public event EventHandler<IReadOnlyDictionary<AlertKey, AlertState>>? SyncAlerts;
@@ -27,6 +29,12 @@ public override void Initialize()
2729
SubscribeLocalEvent<AlertsComponent, LocalPlayerDetachedEvent>(OnPlayerDetached);
2830
SubscribeLocalEvent<AlertsComponent, ComponentHandleState>(OnHandleState);
2931
}
32+
33+
protected override void HandledAlert()
34+
{
35+
_ui.ClickSound();
36+
}
37+
3038
protected override void LoadPrototypes()
3139
{
3240
base.LoadPrototypes();
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
using Content.Shared.Atmos.Components;
2+
using Content.Shared.Atmos.EntitySystems;
3+
4+
namespace Content.Client.Atmos.EntitySystems;
5+
6+
public sealed class GasTankSystem : SharedGasTankSystem
7+
{
8+
public override void Initialize()
9+
{
10+
base.Initialize();
11+
SubscribeLocalEvent<GasTankComponent, AfterAutoHandleStateEvent>(OnGasTankState);
12+
}
13+
14+
private void OnGasTankState(Entity<GasTankComponent> ent, ref AfterAutoHandleStateEvent args)
15+
{
16+
if (UI.TryGetOpenUi(ent.Owner, SharedGasTankUiKey.Key, out var bui))
17+
{
18+
bui.Update<GasTankBoundUserInterfaceState>();
19+
}
20+
}
21+
22+
public override void UpdateUserInterface(Entity<GasTankComponent> ent)
23+
{
24+
if (UI.TryGetOpenUi(ent.Owner, SharedGasTankUiKey.Key, out var bui))
25+
{
26+
bui.Update<GasTankBoundUserInterfaceState>();
27+
}
28+
}
29+
}
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
using Content.Client.Atmos.UI;
2+
using Content.Shared.Atmos.Piping.Binary.Components;
3+
using Content.Shared.Atmos.Piping.Unary.Components;
4+
using Content.Shared.Atmos.Piping.Unary.Systems;
5+
using Content.Shared.NodeContainer;
6+
7+
namespace Content.Client.Atmos.Piping.Unary.Systems;
8+
9+
public sealed class GasCanisterSystem : SharedGasCanisterSystem
10+
{
11+
public override void Initialize()
12+
{
13+
base.Initialize();
14+
SubscribeLocalEvent<GasCanisterComponent, AfterAutoHandleStateEvent>(OnGasState);
15+
}
16+
17+
private void OnGasState(Entity<GasCanisterComponent> ent, ref AfterAutoHandleStateEvent args)
18+
{
19+
if (UI.TryGetOpenUi<GasCanisterBoundUserInterface>(ent.Owner, GasCanisterUiKey.Key, out var bui))
20+
{
21+
bui.Update<GasCanisterBoundUserInterfaceState>();
22+
}
23+
}
24+
25+
protected override void DirtyUI(EntityUid uid, GasCanisterComponent? component = null, NodeContainerComponent? nodes = null)
26+
{
27+
if (UI.TryGetOpenUi<GasCanisterBoundUserInterface>(uid, GasCanisterUiKey.Key, out var bui))
28+
{
29+
bui.Update<GasCanisterBoundUserInterfaceState>();
30+
}
31+
}
32+
}

Content.Client/Atmos/UI/GasCanisterBoundUserInterface.cs

Lines changed: 18 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
using Content.Shared.Atmos.Piping.Binary.Components;
1+
using Content.Shared.Atmos.Components;
2+
using Content.Shared.Atmos.Piping.Binary.Components;
3+
using Content.Shared.Atmos.Piping.Unary.Components;
4+
using Content.Shared.IdentityManagement;
25
using JetBrains.Annotations;
36
using Robust.Client.GameObjects;
47
using Robust.Client.UserInterface;
@@ -32,22 +35,22 @@ protected override void Open()
3235

3336
private void OnTankEjectPressed()
3437
{
35-
SendMessage(new GasCanisterHoldingTankEjectMessage());
38+
SendPredictedMessage(new GasCanisterHoldingTankEjectMessage());
3639
}
3740

3841
private void OnReleasePressureSet(float value)
3942
{
40-
SendMessage(new GasCanisterChangeReleasePressureMessage(value));
43+
SendPredictedMessage(new GasCanisterChangeReleasePressureMessage(value));
4144
}
4245

4346
private void OnReleaseValveOpenPressed()
4447
{
45-
SendMessage(new GasCanisterChangeReleaseValveMessage(true));
48+
SendPredictedMessage(new GasCanisterChangeReleaseValveMessage(true));
4649
}
4750

4851
private void OnReleaseValveClosePressed()
4952
{
50-
SendMessage(new GasCanisterChangeReleaseValveMessage(false));
53+
SendPredictedMessage(new GasCanisterChangeReleaseValveMessage(false));
5154
}
5255

5356
/// <summary>
@@ -57,17 +60,21 @@ private void OnReleaseValveClosePressed()
5760
protected override void UpdateState(BoundUserInterfaceState state)
5861
{
5962
base.UpdateState(state);
60-
if (_window == null || state is not GasCanisterBoundUserInterfaceState cast)
63+
if (_window == null || state is not GasCanisterBoundUserInterfaceState cast || !EntMan.TryGetComponent(Owner, out GasCanisterComponent? component))
6164
return;
6265

63-
_window.SetCanisterLabel(cast.CanisterLabel);
66+
var canisterLabel = Identity.Name(Owner, EntMan);
67+
var tankLabel = component.GasTankSlot.Item != null ? Identity.Name(component.GasTankSlot.Item.Value, EntMan) : null;
68+
69+
_window.SetCanisterLabel(canisterLabel);
6470
_window.SetCanisterPressure(cast.CanisterPressure);
6571
_window.SetPortStatus(cast.PortStatus);
66-
_window.SetTankLabel(cast.TankLabel);
72+
73+
_window.SetTankLabel(tankLabel);
6774
_window.SetTankPressure(cast.TankPressure);
68-
_window.SetReleasePressureRange(cast.ReleasePressureMin, cast.ReleasePressureMax);
69-
_window.SetReleasePressure(cast.ReleasePressure);
70-
_window.SetReleaseValve(cast.ReleaseValve);
75+
_window.SetReleasePressureRange(component.MinReleasePressure, component.MaxReleasePressure);
76+
_window.SetReleasePressure(component.ReleasePressure);
77+
_window.SetReleaseValve(component.ReleaseValve);
7178
}
7279

7380
protected override void Dispose(bool disposing)

Content.Client/Atmos/UI/GasPressurePumpBoundUserInterface.cs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,6 @@ namespace Content.Client.Atmos.UI;
1313
[UsedImplicitly]
1414
public sealed class GasPressurePumpBoundUserInterface(EntityUid owner, Enum uiKey) : BoundUserInterface(owner, uiKey)
1515
{
16-
[ViewVariables]
17-
private const float MaxPressure = Atmospherics.MaxOutputPressure;
18-
1916
[ViewVariables]
2017
private GasPressurePumpWindow? _window;
2118

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
using Content.Shared.Atmos.Components;
2+
using Content.Shared.Body.Components;
3+
using Content.Shared.Body.Systems;
4+
5+
namespace Content.Client.Body.Systems;
6+
7+
public sealed class InternalsSystem : SharedInternalsSystem
8+
{
9+
[Dependency] private readonly SharedUserInterfaceSystem _ui = default!;
10+
11+
public override void Initialize()
12+
{
13+
base.Initialize();
14+
SubscribeLocalEvent<InternalsComponent, AfterAutoHandleStateEvent>(OnInternalsAfterState);
15+
}
16+
17+
private void OnInternalsAfterState(Entity<InternalsComponent> ent, ref AfterAutoHandleStateEvent args)
18+
{
19+
if (ent.Comp.GasTankEntity != null && _ui.TryGetOpenUi(ent.Comp.GasTankEntity.Value, SharedGasTankUiKey.Key, out var bui))
20+
{
21+
bui.Update();
22+
}
23+
}
24+
}

Content.Client/Cargo/UI/CargoConsoleMenu.xaml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,10 @@
3838
<!-- Products get added here by code -->
3939
</BoxContainer>
4040
</ScrollContainer>
41-
<Control MinHeight="5"/>
41+
<Control MinHeight="5" Name="OrdersSpacer"/>
4242
<PanelContainer VerticalExpand="True"
43-
SizeFlagsStretchRatio="1">
43+
SizeFlagsStretchRatio="1"
44+
Name="Orders">
4445
<PanelContainer.PanelOverride>
4546
<gfx:StyleBoxFlat BackgroundColor="#000000" />
4647
</PanelContainer.PanelOverride>

Content.Client/Cargo/UI/CargoConsoleMenu.xaml.cs

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -208,6 +208,7 @@ public void PopulateOrders(IEnumerable<CargoOrderData> orders)
208208

209209
var product = _protoManager.Index<EntityPrototype>(order.ProductId);
210210
var productName = product.Name;
211+
var account = _protoManager.Index(order.Account);
211212

212213
var row = new CargoOrderRow
213214
{
@@ -219,7 +220,9 @@ public void PopulateOrders(IEnumerable<CargoOrderData> orders)
219220
"cargo-console-menu-populate-orders-cargo-order-row-product-name-text",
220221
("productName", productName),
221222
("orderAmount", order.OrderQuantity),
222-
("orderRequester", order.Requester))
223+
("orderRequester", order.Requester),
224+
("accountColor", account.Color),
225+
("account", Loc.GetString(account.Code)))
223226
},
224227
Description =
225228
{
@@ -282,6 +285,9 @@ protected override void FrameUpdate(FrameEventArgs args)
282285
AccountActionButton.Disabled = TransferSpinBox.Value <= 0 ||
283286
TransferSpinBox.Value > bankAccount.Accounts[orderConsole.Account] * orderConsole.TransferLimit ||
284287
_timing.CurTime < orderConsole.NextAccountActionTime;
288+
289+
OrdersSpacer.Visible = !orderConsole.SlipPrinter;
290+
Orders.Visible = !orderConsole.SlipPrinter;
285291
}
286292
}
287293
}

0 commit comments

Comments
 (0)