Salvage dungeons (#14520)

This commit is contained in:
metalgearsloth
2023-03-10 16:41:22 +11:00
committed by GitHub
parent 214ca06997
commit 6157dfa3c0
145 changed files with 24649 additions and 396 deletions

View File

@@ -2,6 +2,7 @@ using Content.Server.Cargo.Components;
using Content.Server.Station.Systems;
using Content.Shared.Cargo;
using Content.Shared.Containers.ItemSlots;
using JetBrains.Annotations;
using Robust.Shared.Prototypes;
namespace Content.Server.Cargo.Systems;
@@ -44,9 +45,20 @@ public sealed partial class CargoSystem : SharedCargoSystem
UpdateTelepad(frameTime);
}
// please don't delete this thank you
[PublicAPI]
public void UpdateBankAccount(StationBankAccountComponent component, int balanceAdded)
{
component.Balance += balanceAdded;
// TODO: Code bad
foreach (var comp in EntityQuery<CargoOrderConsoleComponent>())
{
if (!_uiSystem.IsUiOpen(comp.Owner, CargoConsoleUiKey.Orders)) continue;
var station = _station.GetOwningStation(comp.Owner);
if (station != component.Owner)
continue;
UpdateOrderState(comp, station);
}
}
}