Fix 3000 errors

This commit is contained in:
DrSmugleaf
2021-12-05 18:09:01 +01:00
parent 2bfec7ec62
commit 2a3b7d809d
569 changed files with 2979 additions and 3280 deletions

View File

@@ -135,11 +135,11 @@ namespace Content.Client.Instruments.UI
var instrument = _owner.Instrument;
// If either the entity or component are null, return.
if (instrumentEnt == null || instrument == null)
if (instrumentEnt == default || instrument == default)
return false;
// If we're a handheld instrument, we might be in a container. Get it just in case.
instrumentEnt.TryGetContainerMan(out var conMan);
instrumentEnt.Value.TryGetContainerMan(out var conMan);
var localPlayer = IoCManager.Resolve<IPlayerManager>().LocalPlayer;
@@ -151,7 +151,7 @@ namespace Content.Client.Instruments.UI
|| conMan.Owner != localPlayer.ControlledEntity))) return false;
// We check that we're in range unobstructed just in case.
return localPlayer.InRangeUnobstructed(instrumentEnt,
return localPlayer.InRangeUnobstructed(instrumentEnt.Value,
predicate: (e) => e == instrumentEnt || e == localPlayer.ControlledEntity);
}