From da7cf45fa6da7bf10473c9ba2aa97bc7182c66f0 Mon Sep 17 00:00:00 2001 From: deltanedas <39013340+deltanedas@users.noreply.github.com> Date: Tue, 10 Dec 2024 18:37:43 +0000 Subject: [PATCH] Port DeltaV Lavaland Initial --- .../Shuttles/Systems/DockingConsoleSystem.cs | 5 + .../UI/DockingConsoleBoundUserInterface.cs | 38 + .../Shuttles/UI/DockingConsoleWindow.xaml | 17 + .../Shuttles/UI/DockingConsoleWindow.xaml.cs | 112 + Content.Server/DeltaV/Planet/PlanetSystem.cs | 76 + .../Shuttles/Systems/DockingConsoleSystem.cs | 164 + .../Shuttles/Systems/DockingShuttleSystem.cs | 79 + .../StationPlanetSpawnerComponent.cs | 32 + .../Systems/StationPlanetSpawnerSystem.cs | 30 + .../DeltaV/Planet/PlanetPrototype.cs | 49 + .../Components/DockingConsoleComponent.cs | 48 + .../Components/DockingShuttleComponent.cs | 46 + .../Components/MiningShuttleComponent.cs | 10 + .../DeltaV/Shuttles/DockingConsoleUI.cs | 26 + .../Systems/SharedDockingConsoleSystem.cs | 3 + .../Systems/SharedDockingShuttleSystem.cs | 3 + .../en-US/deltav/shuttles/docking-console.ftl | 7 + .../DeltaV/lavaland_mining_base.yml | 3887 +++++++++++++++++ Resources/Maps/Shuttles/DeltaV/mining.yml | 495 +++ .../Catalog/Fills/Lockers/heads.yml | 1 + .../Entities/Stations/nanotrasen.yml | 1 + .../Recipes/Construction/structures.yml | 19 +- 22 files changed, 5141 insertions(+), 7 deletions(-) create mode 100644 Content.Client/DeltaV/Shuttles/Systems/DockingConsoleSystem.cs create mode 100644 Content.Client/DeltaV/Shuttles/UI/DockingConsoleBoundUserInterface.cs create mode 100644 Content.Client/DeltaV/Shuttles/UI/DockingConsoleWindow.xaml create mode 100644 Content.Client/DeltaV/Shuttles/UI/DockingConsoleWindow.xaml.cs create mode 100644 Content.Server/DeltaV/Planet/PlanetSystem.cs create mode 100644 Content.Server/DeltaV/Shuttles/Systems/DockingConsoleSystem.cs create mode 100644 Content.Server/DeltaV/Shuttles/Systems/DockingShuttleSystem.cs create mode 100644 Content.Server/DeltaV/Station/Components/StationPlanetSpawnerComponent.cs create mode 100644 Content.Server/DeltaV/Station/Systems/StationPlanetSpawnerSystem.cs create mode 100644 Content.Shared/DeltaV/Planet/PlanetPrototype.cs create mode 100644 Content.Shared/DeltaV/Shuttles/Components/DockingConsoleComponent.cs create mode 100644 Content.Shared/DeltaV/Shuttles/Components/DockingShuttleComponent.cs create mode 100644 Content.Shared/DeltaV/Shuttles/Components/MiningShuttleComponent.cs create mode 100644 Content.Shared/DeltaV/Shuttles/DockingConsoleUI.cs create mode 100644 Content.Shared/DeltaV/Shuttles/Systems/SharedDockingConsoleSystem.cs create mode 100644 Content.Shared/DeltaV/Shuttles/Systems/SharedDockingShuttleSystem.cs create mode 100644 Resources/Locale/en-US/deltav/shuttles/docking-console.ftl create mode 100644 Resources/Maps/Nonstations/DeltaV/lavaland_mining_base.yml create mode 100644 Resources/Maps/Shuttles/DeltaV/mining.yml diff --git a/Content.Client/DeltaV/Shuttles/Systems/DockingConsoleSystem.cs b/Content.Client/DeltaV/Shuttles/Systems/DockingConsoleSystem.cs new file mode 100644 index 0000000000..5e0df6ae5d --- /dev/null +++ b/Content.Client/DeltaV/Shuttles/Systems/DockingConsoleSystem.cs @@ -0,0 +1,5 @@ +using Content.Shared.DeltaV.Shuttles.Systems; + +namespace Content.Client.DeltaV.Shuttles.Systems; + +public sealed class DockingConsoleSystem : SharedDockingConsoleSystem; diff --git a/Content.Client/DeltaV/Shuttles/UI/DockingConsoleBoundUserInterface.cs b/Content.Client/DeltaV/Shuttles/UI/DockingConsoleBoundUserInterface.cs new file mode 100644 index 0000000000..450ffc04a1 --- /dev/null +++ b/Content.Client/DeltaV/Shuttles/UI/DockingConsoleBoundUserInterface.cs @@ -0,0 +1,38 @@ +using Content.Shared.DeltaV.Shuttles; + +namespace Content.Client.DeltaV.Shuttles.UI; + +public sealed class DockingConsoleBoundUserInterface : BoundUserInterface +{ + [ViewVariables] + private DockingConsoleWindow? _window; + + public DockingConsoleBoundUserInterface(EntityUid owner, Enum uiKey) : base(owner, uiKey) + { + } + + protected override void Open() + { + base.Open(); + + _window = new DockingConsoleWindow(Owner); + _window.OnFTL += index => SendMessage(new DockingConsoleFTLMessage(index)); + _window.OnClose += Close; + _window.OpenCentered(); + } + + protected override void UpdateState(BoundUserInterfaceState state) + { + base.UpdateState(state); + if (state is DockingConsoleState cast) + _window?.UpdateState(cast); + } + + protected override void Dispose(bool disposing) + { + base.Dispose(disposing); + + if (disposing) + _window?.Orphan(); + } +} diff --git a/Content.Client/DeltaV/Shuttles/UI/DockingConsoleWindow.xaml b/Content.Client/DeltaV/Shuttles/UI/DockingConsoleWindow.xaml new file mode 100644 index 0000000000..595a30be80 --- /dev/null +++ b/Content.Client/DeltaV/Shuttles/UI/DockingConsoleWindow.xaml @@ -0,0 +1,17 @@ + + + + + + + +