allow decals to be removed from placement menu (#9843)
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
using System.Linq;
|
using System.Linq;
|
||||||
using Content.Client.Stylesheets;
|
using Content.Client.Stylesheets;
|
||||||
using Content.Shared.Decals;
|
using Content.Shared.Decals;
|
||||||
using Robust.Client.AutoGenerated;
|
using Robust.Client.AutoGenerated;
|
||||||
@@ -179,7 +179,8 @@ public sealed partial class DecalPlacerWindow : DefaultWindow
|
|||||||
_decals = new Dictionary<string, Texture>();
|
_decals = new Dictionary<string, Texture>();
|
||||||
foreach (var decalPrototype in prototypes)
|
foreach (var decalPrototype in prototypes)
|
||||||
{
|
{
|
||||||
_decals.Add(decalPrototype.ID, decalPrototype.Sprite.Frame0());
|
if (decalPrototype.ShowMenu)
|
||||||
|
_decals.Add(decalPrototype.ID, decalPrototype.Sprite.Frame0());
|
||||||
}
|
}
|
||||||
|
|
||||||
RefreshList();
|
RefreshList();
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
using Robust.Shared.Prototypes;
|
using Robust.Shared.Prototypes;
|
||||||
using Robust.Shared.Utility;
|
using Robust.Shared.Utility;
|
||||||
|
|
||||||
namespace Content.Shared.Decals
|
namespace Content.Shared.Decals
|
||||||
@@ -9,5 +9,6 @@ namespace Content.Shared.Decals
|
|||||||
[IdDataFieldAttribute] public string ID { get; } = null!;
|
[IdDataFieldAttribute] public string ID { get; } = null!;
|
||||||
[DataField("sprite")] public SpriteSpecifier Sprite { get; } = SpriteSpecifier.Invalid;
|
[DataField("sprite")] public SpriteSpecifier Sprite { get; } = SpriteSpecifier.Invalid;
|
||||||
[DataField("tags")] public List<string> Tags = new();
|
[DataField("tags")] public List<string> Tags = new();
|
||||||
|
[DataField("showMenu")] public bool ShowMenu = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -142,6 +142,7 @@
|
|||||||
|
|
||||||
- type: decal
|
- type: decal
|
||||||
id: WarnEnd
|
id: WarnEnd
|
||||||
|
showMenu: false
|
||||||
tags: ["station", "markings"]
|
tags: ["station", "markings"]
|
||||||
sprite:
|
sprite:
|
||||||
sprite: Decals/markings.rsi
|
sprite: Decals/markings.rsi
|
||||||
@@ -149,6 +150,7 @@
|
|||||||
|
|
||||||
- type: decal
|
- type: decal
|
||||||
id: WarnEndGreyscale
|
id: WarnEndGreyscale
|
||||||
|
showMenu: false
|
||||||
tags: ["station", "markings"]
|
tags: ["station", "markings"]
|
||||||
sprite:
|
sprite:
|
||||||
sprite: Decals/markings.rsi
|
sprite: Decals/markings.rsi
|
||||||
@@ -174,6 +176,7 @@
|
|||||||
|
|
||||||
- type: decal
|
- type: decal
|
||||||
id: WarningLine
|
id: WarningLine
|
||||||
|
showMenu: false
|
||||||
tags: ["station", "markings"]
|
tags: ["station", "markings"]
|
||||||
sprite:
|
sprite:
|
||||||
sprite: Decals/markings.rsi
|
sprite: Decals/markings.rsi
|
||||||
@@ -181,6 +184,7 @@
|
|||||||
|
|
||||||
- type: decal
|
- type: decal
|
||||||
id: WarningLineGreyscale
|
id: WarningLineGreyscale
|
||||||
|
showMenu: false
|
||||||
tags: ["station", "markings"]
|
tags: ["station", "markings"]
|
||||||
sprite:
|
sprite:
|
||||||
sprite: Decals/markings.rsi
|
sprite: Decals/markings.rsi
|
||||||
@@ -188,6 +192,7 @@
|
|||||||
|
|
||||||
- type: decal
|
- type: decal
|
||||||
id: WarningLineCorner
|
id: WarningLineCorner
|
||||||
|
showMenu: false
|
||||||
tags: ["station", "markings"]
|
tags: ["station", "markings"]
|
||||||
sprite:
|
sprite:
|
||||||
sprite: Decals/markings.rsi
|
sprite: Decals/markings.rsi
|
||||||
@@ -195,6 +200,7 @@
|
|||||||
|
|
||||||
- type: decal
|
- type: decal
|
||||||
id: WarningLineCornerGreyscale
|
id: WarningLineCornerGreyscale
|
||||||
|
showMenu: false
|
||||||
tags: ["station", "markings"]
|
tags: ["station", "markings"]
|
||||||
sprite:
|
sprite:
|
||||||
sprite: Decals/markings.rsi
|
sprite: Decals/markings.rsi
|
||||||
@@ -202,6 +208,7 @@
|
|||||||
|
|
||||||
- type: decal
|
- type: decal
|
||||||
id: WarningLineCornerFlipped
|
id: WarningLineCornerFlipped
|
||||||
|
showMenu: false
|
||||||
tags: ["station", "markings"]
|
tags: ["station", "markings"]
|
||||||
sprite:
|
sprite:
|
||||||
sprite: Decals/markings.rsi
|
sprite: Decals/markings.rsi
|
||||||
@@ -209,6 +216,7 @@
|
|||||||
|
|
||||||
- type: decal
|
- type: decal
|
||||||
id: WarningLineCornerFlippedGreyscale
|
id: WarningLineCornerFlippedGreyscale
|
||||||
|
showMenu: false
|
||||||
tags: ["station", "markings"]
|
tags: ["station", "markings"]
|
||||||
sprite:
|
sprite:
|
||||||
sprite: Decals/markings.rsi
|
sprite: Decals/markings.rsi
|
||||||
@@ -216,6 +224,7 @@
|
|||||||
|
|
||||||
- type: decal
|
- type: decal
|
||||||
id: WarnCorner
|
id: WarnCorner
|
||||||
|
showMenu: false
|
||||||
tags: ["station", "markings"]
|
tags: ["station", "markings"]
|
||||||
sprite:
|
sprite:
|
||||||
sprite: Decals/markings.rsi
|
sprite: Decals/markings.rsi
|
||||||
@@ -223,6 +232,7 @@
|
|||||||
|
|
||||||
- type: decal
|
- type: decal
|
||||||
id: WarnCornerGreyscale
|
id: WarnCornerGreyscale
|
||||||
|
showMenu: false
|
||||||
tags: ["station", "markings"]
|
tags: ["station", "markings"]
|
||||||
sprite:
|
sprite:
|
||||||
sprite: Decals/markings.rsi
|
sprite: Decals/markings.rsi
|
||||||
@@ -230,6 +240,7 @@
|
|||||||
|
|
||||||
- type: decal
|
- type: decal
|
||||||
id: WarnCornerFlipped
|
id: WarnCornerFlipped
|
||||||
|
showMenu: false
|
||||||
tags: ["station", "markings"]
|
tags: ["station", "markings"]
|
||||||
sprite:
|
sprite:
|
||||||
sprite: Decals/markings.rsi
|
sprite: Decals/markings.rsi
|
||||||
@@ -237,6 +248,7 @@
|
|||||||
|
|
||||||
- type: decal
|
- type: decal
|
||||||
id: WarnCornerFlippedGreyscale
|
id: WarnCornerFlippedGreyscale
|
||||||
|
showMenu: false
|
||||||
tags: ["station", "markings"]
|
tags: ["station", "markings"]
|
||||||
sprite:
|
sprite:
|
||||||
sprite: Decals/markings.rsi
|
sprite: Decals/markings.rsi
|
||||||
|
|||||||
Reference in New Issue
Block a user