Add mapping editor (#23427)
* Add mapping editor (#757) * Remove mapping actions, never again * Cleanup actions system * Jarvis, remove all references to CM14 * Fix InventoryUIController crashing when an InventoryGui is not found * Rename mapping1 to mapping * Clean up context calls * Add doc comments * Add delegate for hiding decals in the mapping screen * Jarvis mission failed * a * Add test * Fix not flushing save stream in mapping manager * change * Fix verbs * fixes * localise --------- Co-authored-by: DrSmugleaf <DrSmugleaf@users.noreply.github.com> Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com> Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com> Co-authored-by: Pieter-Jan Briers <pieterjan.briers+git@gmail.com>
This commit is contained in:
39
Content.Client/Mapping/MappingPrototype.cs
Normal file
39
Content.Client/Mapping/MappingPrototype.cs
Normal file
@@ -0,0 +1,39 @@
|
||||
using Content.Shared.Decals;
|
||||
using Content.Shared.Maps;
|
||||
using Robust.Shared.Prototypes;
|
||||
|
||||
namespace Content.Client.Mapping;
|
||||
|
||||
/// <summary>
|
||||
/// Used to represent a button's data in the mapping editor.
|
||||
/// </summary>
|
||||
public sealed class MappingPrototype
|
||||
{
|
||||
/// <summary>
|
||||
/// The prototype instance, if any.
|
||||
/// Can be one of <see cref="EntityPrototype"/>, <see cref="ContentTileDefinition"/> or <see cref="DecalPrototype"/>
|
||||
/// If null, this is a top-level button (such as Entities, Tiles or Decals)
|
||||
/// </summary>
|
||||
public readonly IPrototype? Prototype;
|
||||
|
||||
/// <summary>
|
||||
/// The text to display on the UI for this button.
|
||||
/// </summary>
|
||||
public readonly string Name;
|
||||
|
||||
/// <summary>
|
||||
/// Which other prototypes (buttons) this one is nested inside of.
|
||||
/// </summary>
|
||||
public List<MappingPrototype>? Parents;
|
||||
|
||||
/// <summary>
|
||||
/// Which other prototypes (buttons) are nested inside this one.
|
||||
/// </summary>
|
||||
public List<MappingPrototype>? Children;
|
||||
|
||||
public MappingPrototype(IPrototype? prototype, string name)
|
||||
{
|
||||
Prototype = prototype;
|
||||
Name = name;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user