Update submodule, fix a bunch of warnings.

This commit is contained in:
Pieter-Jan Briers
2021-02-23 22:26:59 +01:00
parent ade8c6115b
commit 5a7658a13b
24 changed files with 40 additions and 43 deletions

View File

@@ -1,11 +1,9 @@
using System;
using System.Collections.Generic;
using System.Globalization;
using Content.Shared.Chemistry;
using Content.Shared.Maps;
using Robust.Shared.ContentPack;
using Robust.Shared.IoC;
using Robust.Shared.Localization;
using Robust.Shared.Log;
using Robust.Shared.Map;
using Robust.Shared.Prototypes;
@@ -16,7 +14,6 @@ namespace Content.Shared
{
[Dependency] private readonly IPrototypeManager _prototypeManager = default!;
[Dependency] private readonly ITileDefinitionManager _tileDefinitionManager = default!;
[Dependency] private readonly IResourceManager _resourceManager = default!;
public override void PreInit()
{

View File

@@ -199,7 +199,7 @@ namespace Content.Shared.GameObjects.Components.Chemistry
}
var primaryReagent = Solution.GetPrimaryReagentId();
if (!prototypeManager.TryIndex(primaryReagent, out ReagentPrototype proto))
if (!prototypeManager.TryIndex(primaryReagent, out ReagentPrototype? proto))
{
Logger.Error($"{nameof(SharedSolutionContainerComponent)} could not find the prototype associated with {primaryReagent}.");
return;

View File

@@ -18,7 +18,7 @@ namespace Content.Shared
var culture = new CultureInfo(Culture);
loc.LoadCulture(res, culture);
loc.LoadCulture(culture);
loc.AddFunction(culture, "PRESSURE", FormatPressure);
loc.AddFunction(culture, "TOSTRING", args => FormatToString(culture, args));
}

View File

@@ -33,7 +33,7 @@ namespace Content.Shared.Utility
{
prototypeManager ??= IoCManager.Resolve<IPrototypeManager>();
return prototypeManager.TryIndex(prototype, out EntityPrototype proto) && proto.HasComponent(component, componentFactory);
return prototypeManager.TryIndex(prototype, out EntityPrototype? proto) && proto.HasComponent(component, componentFactory);
}
}
}