From d7e0b70e2c9016905c0c1ed93fa233dda00f3524 Mon Sep 17 00:00:00 2001 From: Nemanja <98561806+EmoGarbage404@users.noreply.github.com> Date: Thu, 18 Aug 2022 20:04:23 -0400 Subject: [PATCH] revenant cleanup (#10662) --- .../Revenant/Ui/RevenantBoundUserInterface.cs | 54 ------------- .../Revenant/Ui/RevenantListingControl.xaml | 21 ----- .../Ui/RevenantListingControl.xaml.cs | 26 ------- Content.Client/Revenant/Ui/RevenantMenu.xaml | 41 ---------- .../Revenant/Ui/RevenantMenu.xaml.cs | 62 --------------- .../EntitySystems/RevenantSystem.Abilities.cs | 6 +- .../EntitySystems/RevenantSystem.Shop.cs | 69 ----------------- .../Revenant/EntitySystems/RevenantSystem.cs | 19 +++-- Content.Server/Revenant/RevenantComponent.cs | 14 +--- .../Store/Systems/StoreSystem.Ui.cs | 4 +- Content.Server/Store/Systems/StoreSystem.cs | 1 - .../Revenant/RevenantStoreListingPrototype.cs | 30 -------- Content.Shared/Revenant/SharedRevenant.cs | 31 -------- Resources/Locale/en-US/store/currency.ftl | 5 +- .../Prototypes/Catalog/revenant_catalog.yml | 77 ++++++++++++------- .../Entities/Mobs/NPCs/revenant.yml | 9 ++- Resources/Prototypes/Store/categories.yml | 5 ++ Resources/Prototypes/Store/currency.yml | 6 ++ 18 files changed, 92 insertions(+), 388 deletions(-) delete mode 100644 Content.Client/Revenant/Ui/RevenantBoundUserInterface.cs delete mode 100644 Content.Client/Revenant/Ui/RevenantListingControl.xaml delete mode 100644 Content.Client/Revenant/Ui/RevenantListingControl.xaml.cs delete mode 100644 Content.Client/Revenant/Ui/RevenantMenu.xaml delete mode 100644 Content.Client/Revenant/Ui/RevenantMenu.xaml.cs delete mode 100644 Content.Server/Revenant/EntitySystems/RevenantSystem.Shop.cs delete mode 100644 Content.Shared/Revenant/RevenantStoreListingPrototype.cs diff --git a/Content.Client/Revenant/Ui/RevenantBoundUserInterface.cs b/Content.Client/Revenant/Ui/RevenantBoundUserInterface.cs deleted file mode 100644 index 17f7d88875..0000000000 --- a/Content.Client/Revenant/Ui/RevenantBoundUserInterface.cs +++ /dev/null @@ -1,54 +0,0 @@ -using Content.Shared.Revenant; -using JetBrains.Annotations; -using Robust.Client.GameObjects; - -namespace Content.Client.Revenant.Ui; - -[UsedImplicitly] -public sealed class RevenantBoundUserInterface : BoundUserInterface -{ - private RevenantMenu? _menu; - - public RevenantBoundUserInterface(ClientUserInterfaceComponent owner, object uiKey) : base(owner, uiKey) - { - - } - - protected override void Open() - { - _menu = new(); - _menu.OpenCentered(); - _menu.OnClose += Close; - - _menu.OnListingButtonPressed += (_, listing) => - { - SendMessage(new RevenantBuyListingMessage(listing)); - }; - } - - protected override void UpdateState(BoundUserInterfaceState state) - { - base.UpdateState(state); - - if (_menu == null) - return; - - switch (state) - { - case RevenantUpdateState msg: - _menu.UpdateEssence(msg.Essence); - _menu.UpdateListing(msg.Listings); - break; - } - } - - protected override void Dispose(bool disposing) - { - base.Dispose(disposing); - if (!disposing) - return; - - _menu?.Close(); - _menu?.Dispose(); - } -} diff --git a/Content.Client/Revenant/Ui/RevenantListingControl.xaml b/Content.Client/Revenant/Ui/RevenantListingControl.xaml deleted file mode 100644 index 6adcfdc896..0000000000 --- a/Content.Client/Revenant/Ui/RevenantListingControl.xaml +++ /dev/null @@ -1,21 +0,0 @@ - - - -