Construction recipes can specify if they should be build-able in… (#781)

Co-authored-by: py01 <pyronetics01@gmail.com>
This commit is contained in:
py01
2020-03-06 13:15:44 -06:00
committed by GitHub
parent e17ffbd76f
commit aecff31262
5 changed files with 24 additions and 2 deletions

View File

@@ -21,6 +21,7 @@ namespace Content.Shared.Construction
private string _id;
private string _result;
private string _placementMode;
private bool _canBuildInImpassable;
/// <summary>
/// Friendly name displayed in the construction GUI.
@@ -37,6 +38,11 @@ namespace Content.Shared.Construction
/// </summary>
public SpriteSpecifier Icon => _icon;
/// <summary>
/// If you can start building or complete steps on impassable terrain.
/// </summary>
public bool CanBuildInImpassable => _canBuildInImpassable;
/// <summary>
/// A list of keywords that are used for searching.
/// </summary>
@@ -81,6 +87,7 @@ namespace Content.Shared.Construction
ser.DataField(ref _type, "objecttype", ConstructionType.Structure);
ser.DataField(ref _result, "result", null);
ser.DataField(ref _placementMode, "placementmode", "PlaceFree");
ser.DataField(ref _canBuildInImpassable, "canbuildinimpassable", false);
_keywords = ser.ReadDataField<List<string>>("keywords", new List<string>());
{