Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shipyard #19

Open
wants to merge 11 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
class and cleanup
Cheackraze committed Feb 14, 2023
commit a7cbea8b58b889f7b76702219747077a1523eede
1 change: 0 additions & 1 deletion Content.Client/Shipyard/UI/VesselRow.xaml.cs
Original file line number Diff line number Diff line change
@@ -10,7 +10,6 @@ namespace Content.Client.Shipyard.UI;
public sealed partial class VesselRow : PanelContainer
{
public VesselPrototype? Vessel;

public VesselRow()
{
RobustXamlLoader.Load(this);
8 changes: 2 additions & 6 deletions Content.Server/Shipyard/Systems/ShipyardSystem.Consoles.cs
Original file line number Diff line number Diff line change
@@ -2,8 +2,6 @@
using Content.Server.Cargo.Systems;
using Content.Server.Cargo.Components;
using Content.Server.Radio.EntitySystems;
using Content.Server.Shuttles.Components;
using Content.Server.Station.Systems;
using Content.Shared.Shipyard.Events;
using Content.Shared.Shipyard.BUI;
using Content.Shared.Shipyard.Prototypes;
@@ -19,14 +17,12 @@

namespace Content.Server.Shipyard.Systems;

public sealed class ShipyardConsoleSystem : EntitySystem
public sealed partial class ShipyardSystem
{
[Dependency] private readonly AccessReaderSystem _access = default!;
[Dependency] private readonly PopupSystem _popup = default!;
[Dependency] private readonly UserInterfaceSystem _ui = default!;
[Dependency] private readonly IPrototypeManager _prototypeManager = default!;
[Dependency] private readonly ShipyardSystem _shipyard = default!;
[Dependency] private readonly StationSystem _station = default!;
[Dependency] private readonly CargoSystem _cargo = default!;
[Dependency] private readonly RadioSystem _radio = default!;
[Dependency] private readonly SharedAudioSystem _audio = default!;
@@ -76,7 +72,7 @@ private void OnPurchaseMessage(EntityUid uid, ShipyardConsoleComponent component
return;
}

if (!_shipyard.TryPurchaseShuttle((EntityUid) station, vessel.ShuttlePath.ToString(), out var shuttle))
if (!TryPurchaseShuttle((EntityUid) station, vessel.ShuttlePath.ToString(), out var shuttle))
{
PlayDenySound(uid, component);
return;
3 changes: 1 addition & 2 deletions Content.Server/Shipyard/Systems/ShipyardSystem.cs
Original file line number Diff line number Diff line change
@@ -23,7 +23,6 @@ public sealed partial class ShipyardSystem : EntitySystem
[Dependency] private readonly ShuttleSystem _shuttle = default!;
[Dependency] private readonly StationSystem _station = default!;
[Dependency] private readonly MapLoaderSystem _map = default!;
[Dependency] private readonly ShipyardConsoleSystem _shipyardConsole = default!;

public MapId? ShipyardMap { get; private set; }
private float _shuttleIndex;
@@ -35,7 +34,7 @@ public override void Initialize()
{
_configManager.OnValueChanged(CCVars.Shipyard, SetShipyardEnabled, true);
_sawmill = Logger.GetSawmill("shipyard");
_shipyardConsole.InitializeConsole();
InitializeConsole();
SubscribeLocalEvent<ShipyardConsoleComponent, ComponentInit>(OnShipyardStartup);
SubscribeLocalEvent<RoundRestartCleanupEvent>(OnRoundRestart);
}
4 changes: 0 additions & 4 deletions Content.Shared/Shipyard/SharedShipyardSystem.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
using Content.Shared.Shipyard.Components;
using Content.Shared.Containers.ItemSlots;
using JetBrains.Annotations;
using Robust.Shared.GameStates;
using Robust.Shared.Serialization;

namespace Content.Shared.Shipyard;