* action commands * atmos debug commands * comming * credits command * debug commands * usage * usings * debug pathfinding command * grouping entity menu command * hide mechanisms command * commit * mapping client side setup command * open ahelp command * set menu visibility command * commit * show mechanisms command * toggle health overlay command * toggle outline command * stage * disable once * ioc * namespaces * WriteError * clean up command usage * don't abbriviate * ActionsCommands * AtmosDebugCommands * the rest * oops * undo
27 lines
803 B
C#
27 lines
803 B
C#
using Content.Shared.Body.Organ;
|
|
using Robust.Client.GameObjects;
|
|
using Robust.Shared.Console;
|
|
|
|
namespace Content.Client.Commands;
|
|
|
|
public sealed class ShowMechanismsCommand : LocalizedCommands
|
|
{
|
|
[Dependency] private readonly IEntityManager _entManager = default!;
|
|
|
|
public const string CommandName = "showmechanisms";
|
|
|
|
public override string Command => CommandName;
|
|
|
|
public override string Help => LocalizationManager.GetString($"cmd-{Command}-help", ("command", Command));
|
|
|
|
public override void Execute(IConsoleShell shell, string argStr, string[] args)
|
|
{
|
|
var query = _entManager.AllEntityQueryEnumerator<OrganComponent, SpriteComponent>();
|
|
|
|
while (query.MoveNext(out _, out var sprite))
|
|
{
|
|
sprite.ContainerOccluded = false;
|
|
}
|
|
}
|
|
}
|