Files
tbd-station-14/Content.Server/Cargo/Systems/CargoSystem.cs
metalgearsloth e72e060972 Don't load cargo shuttle by default (#9194)
* Don't load cargo shuttle by default

Realistically only I am going to care and it wastes a few seconds per test / debugging locally.

* Make it a general cvar instead

* a
2022-06-27 14:58:40 +10:00

47 lines
1.3 KiB
C#

using Content.Server.Cargo.Components;
using Content.Server.Station.Systems;
using Content.Shared.Cargo;
using Content.Shared.Cargo.Components;
using Content.Shared.Containers.ItemSlots;
using Robust.Shared.Prototypes;
namespace Content.Server.Cargo.Systems;
public sealed partial class CargoSystem : SharedCargoSystem
{
[Dependency] private readonly IPrototypeManager _protoMan = default!;
[Dependency] private readonly ItemSlotsSystem _slots = default!;
private ISawmill _sawmill = default!;
public override void Initialize()
{
base.Initialize();
_sawmill = Logger.GetSawmill("cargo");
InitializeConsole();
InitializeShuttle();
InitializeTelepad();
SubscribeLocalEvent<StationInitializedEvent>(OnStationInit);
}
public override void Shutdown()
{
base.Shutdown();
ShutdownShuttle();
CleanupShuttle();
}
private void OnStationInit(StationInitializedEvent ev)
{
EnsureComp<StationBankAccountComponent>(ev.Station);
EnsureComp<StationCargoOrderDatabaseComponent>(ev.Station);
}
public override void Update(float frameTime)
{
base.Update(frameTime);
UpdateConsole(frameTime);
UpdateTelepad(frameTime);
}
}