Files
crystall-punk-14/Content.Server/Administration/Commands/Station/ListStationsCommand.cs

25 lines
713 B
C#
Raw Normal View History

2021-11-27 00:43:43 -06:00
using Content.Server.Station;
using Content.Shared.Administration;
using Robust.Shared.Console;
using Robust.Shared.GameObjects;
namespace Content.Server.Administration.Commands.Station;
[AdminCommand(AdminFlags.Admin)]
public sealed class ListStationsCommand : IConsoleCommand
2021-11-27 00:43:43 -06:00
{
public string Command => "lsstations";
public string Description => "List all active stations";
public string Help => "lsstations";
public void Execute(IConsoleShell shell, string argStr, string[] args)
{
foreach (var (id, station) in EntitySystem.Get<StationSystem>().StationInfo)
{
shell.WriteLine($"{id.Id, -2} | {station.Name} | {station.MapPrototype.ID}");
}
}
}