diff --git a/Content.Client/Cargo/BUI/CargoOrderConsoleBoundUserInterface.cs b/Content.Client/Cargo/BUI/CargoOrderConsoleBoundUserInterface.cs index 52846cefdb..73bed8469c 100644 --- a/Content.Client/Cargo/BUI/CargoOrderConsoleBoundUserInterface.cs +++ b/Content.Client/Cargo/BUI/CargoOrderConsoleBoundUserInterface.cs @@ -1,5 +1,6 @@ using Content.Shared.Cargo; using Content.Client.Cargo.UI; +using Content.Shared._DV.Traitor; // DeltaV using Content.Shared.Cargo.BUI; using Content.Shared.Cargo.Components; using Content.Shared.Cargo.Events; @@ -92,6 +93,7 @@ namespace Content.Client.Cargo.BUI }; _menu.OnOrderApproved += ApproveOrder; _menu.OnOrderCanceled += RemoveOrder; + _menu.OnRansomPurchase += ent => SendMessage(new RansomPurchaseMessage(ent)); // DeltaV _orderMenu.SubmitButton.OnPressed += (_) => { if (AddOrder()) @@ -140,6 +142,7 @@ namespace Content.Client.Cargo.BUI _menu?.UpdateStation(station); Populate(cState.Orders); + _menu?.UpdateRansoms(cState.Ransoms, BankBalance); // DeltaV } protected override void Dispose(bool disposing) diff --git a/Content.Client/Cargo/UI/CargoConsoleMenu.xaml b/Content.Client/Cargo/UI/CargoConsoleMenu.xaml index 940352dc48..dc0b3bbf18 100644 --- a/Content.Client/Cargo/UI/CargoConsoleMenu.xaml +++ b/Content.Client/Cargo/UI/CargoConsoleMenu.xaml @@ -1,6 +1,7 @@  @@ -16,6 +17,7 @@ + diff --git a/Content.Client/Cargo/UI/CargoConsoleMenu.xaml.cs b/Content.Client/Cargo/UI/CargoConsoleMenu.xaml.cs index 4c729b795b..17c4531c70 100644 --- a/Content.Client/Cargo/UI/CargoConsoleMenu.xaml.cs +++ b/Content.Client/Cargo/UI/CargoConsoleMenu.xaml.cs @@ -1,6 +1,7 @@ using System.Linq; using Content.Client.Cargo.Systems; using Content.Client.UserInterface.Controls; +using Content.Shared._DV.Traitor; // DeltaV using Content.Shared.Cargo; using Content.Shared.Cargo.Components; using Content.Shared.Cargo.Prototypes; @@ -32,6 +33,7 @@ namespace Content.Client.Cargo.UI public event Action? OnItemSelected; public event Action? OnOrderApproved; public event Action? OnOrderCanceled; + public event Action? OnRansomPurchase; // DeltaV public event Action?, int>? OnAccountAction; @@ -57,6 +59,7 @@ namespace Content.Client.Cargo.UI SearchBar.OnTextChanged += OnSearchBarTextChanged; Categories.OnItemSelected += OnCategoryItemSelected; + RansomContainer.OnPurchase += ent => OnRansomPurchase?.Invoke(ent); // DeltaV if (entMan.TryGetComponent(owner, out var orderConsole)) { @@ -238,6 +241,14 @@ namespace Content.Client.Cargo.UI } } + /// + /// DeltaV: Forwards new ransom data to the ransom container. + /// + public void UpdateRansoms(List ransoms, int balance) + { + RansomContainer.UpdateRansoms(ransoms, balance); + } + public void PopulateAccountActions() { if (!_entityManager.TryGetComponent(_station, out var bank) || @@ -264,6 +275,7 @@ namespace Content.Client.Cargo.UI public void UpdateStation(EntityUid station) { _station = station; + RansomContainer.UpdateStation(_station); // DeltaV } protected override void FrameUpdate(FrameEventArgs args) diff --git a/Content.Client/PDA/PdaBoundUserInterface.cs b/Content.Client/PDA/PdaBoundUserInterface.cs index 2f7ebc37f7..4534b93e37 100644 --- a/Content.Client/PDA/PdaBoundUserInterface.cs +++ b/Content.Client/PDA/PdaBoundUserInterface.cs @@ -1,4 +1,5 @@ using Content.Client.CartridgeLoader; +using Content.Shared._DV.Reputation; // DeltaV using Content.Shared.CartridgeLoader; using Content.Shared.Containers.ItemSlots; using Content.Shared.PDA; @@ -72,6 +73,8 @@ namespace Content.Client.PDA SendMessage(new PdaLockUplinkMessage()); }; + _menu.ContractsButton.OnPressed += _ => SendMessage(new PdaShowContractsMessage()); // DeltaV + _menu.OnProgramItemPressed += ActivateCartridge; _menu.OnInstallButtonPressed += InstallCartridge; _menu.OnUninstallButtonPressed += UninstallCartridge; diff --git a/Content.Client/PDA/PdaMenu.xaml b/Content.Client/PDA/PdaMenu.xaml index 8c9b4ae2ee..dd4030b0e8 100644 --- a/Content.Client/PDA/PdaMenu.xaml +++ b/Content.Client/PDA/PdaMenu.xaml @@ -80,6 +80,13 @@ Visible="False" Text="{Loc 'pda-bound-user-interface-lock-uplink-title'}" Description="{Loc 'pda-bound-user-interface-lock-uplink-description'}"/> + + + programs) diff --git a/Content.Client/Salvage/FultonSystem.cs b/Content.Client/Salvage/FultonSystem.cs index 7e31fbb180..7a3dc4bc07 100644 --- a/Content.Client/Salvage/FultonSystem.cs +++ b/Content.Client/Salvage/FultonSystem.cs @@ -96,7 +96,7 @@ public sealed class FultonSystem : SharedFultonSystem UpdateAppearance(uid, component); } - protected override void UpdateAppearance(EntityUid uid, FultonedComponent component) + public override void UpdateAppearance(EntityUid uid, FultonedComponent component) // DeltaV - made public { if (!component.Effect.IsValid()) return; diff --git a/Content.Client/_DV/Objectives/Systems/ContractObjectiveSystem.cs b/Content.Client/_DV/Objectives/Systems/ContractObjectiveSystem.cs new file mode 100644 index 0000000000..044e70c6be --- /dev/null +++ b/Content.Client/_DV/Objectives/Systems/ContractObjectiveSystem.cs @@ -0,0 +1,5 @@ +using Content.Shared._DV.Objectives.Systems; + +namespace Content.Client._DV.Objectives.Systems; + +public sealed class ContractObjectiveSystem : SharedContractObjectiveSystem; diff --git a/Content.Client/_DV/Reputation/UI/Contract.xaml b/Content.Client/_DV/Reputation/UI/Contract.xaml new file mode 100644 index 0000000000..c0cc23ecfb --- /dev/null +++ b/Content.Client/_DV/Reputation/UI/Contract.xaml @@ -0,0 +1,9 @@ + +