Construction warning cleanup (#12256)

This commit is contained in:
Nemanja
2022-10-30 02:48:53 -04:00
committed by GitHub
parent 1a6d084c4d
commit b6135d3be5
47 changed files with 166 additions and 146 deletions

View File

@@ -7,7 +7,7 @@ namespace Content.Shared.Construction.Steps
{
[DataField("name")] public string Name { get; private set; } = string.Empty;
[DataField("icon")] public SpriteSpecifier? Icon { get; private set; } = null;
[DataField("icon")] public SpriteSpecifier? Icon { get; private set; }
public override void DoExamine(ExaminedEvent examinedEvent)
{
@@ -19,7 +19,7 @@ namespace Content.Shared.Construction.Steps
public override ConstructionGuideEntry GenerateGuideEntry()
{
return new ConstructionGuideEntry()
return new ConstructionGuideEntry
{
Localization = "construction-presenter-arbitrary-step",
Arguments = new (string, object)[]{("name", Name)},

View File

@@ -57,7 +57,8 @@ namespace Content.Shared.Construction.Steps
{
var type = GetType(node);
if (type == null) return new ErrorNode(node, "No construction graph step type found.", true);
if (type == null)
return new ErrorNode(node, "No construction graph step type found.");
return serializationManager.ValidateNode(type, node, context);
}

View File

@@ -25,7 +25,7 @@ namespace Content.Shared.Construction.Steps
if (!entityManager.TryGetComponent(uid, out TagComponent? tags))
return false;
var tagSystem = EntitySystem.Get<TagSystem>();
var tagSystem = entityManager.EntitySysManager.GetEntitySystem<TagSystem>();
if (_allTags != null && !tagSystem.HasAllTags(tags, _allTags))
return false; // We don't have all the tags needed.