Pipe painter (now with airlock painter) (#19031)
* Add a pipe painting function to the airlock painter Signed-off-by: c4llv07e <kseandi@gmail.com> * Rename engineer painter to omnipainter Signed-off-by: c4llv07e <kseandi@gmail.com> * review changes Signed-off-by: c4llv07e <kseandi@gmail.com> * fix migration duplicate Signed-off-by: c4llv07e <kseandi@gmail.com> --------- Signed-off-by: c4llv07e <kseandi@gmail.com>
This commit is contained in:
29
Content.Shared/SprayPainter/SharedDevicePainterSystem.cs
Normal file
29
Content.Shared/SprayPainter/SharedDevicePainterSystem.cs
Normal file
@@ -0,0 +1,29 @@
|
||||
using System.Linq;
|
||||
using Content.Shared.SprayPainter.Prototypes;
|
||||
using Robust.Shared.Prototypes;
|
||||
|
||||
namespace Content.Shared.SprayPainter;
|
||||
|
||||
public abstract class SharedSprayPainterSystem : EntitySystem
|
||||
{
|
||||
[Dependency] protected readonly IPrototypeManager _prototypeManager = default!;
|
||||
|
||||
public List<string> Styles { get; private set; } = new();
|
||||
public List<AirlockGroupPrototype> Groups { get; private set; } = new();
|
||||
|
||||
public override void Initialize()
|
||||
{
|
||||
base.Initialize();
|
||||
|
||||
SortedSet<string> styles = new();
|
||||
foreach (AirlockGroupPrototype grp in _prototypeManager.EnumeratePrototypes<AirlockGroupPrototype>())
|
||||
{
|
||||
Groups.Add(grp);
|
||||
foreach (string style in grp.StylePaths.Keys)
|
||||
{
|
||||
styles.Add(style);
|
||||
}
|
||||
}
|
||||
Styles = styles.ToList();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user