Overlays: Avoid using IEyeManager whenever possible (#5709)

This commit is contained in:
E F R
2021-12-10 05:47:21 +00:00
committed by GitHub
parent b3a4e3f557
commit 8bd386dcb0
13 changed files with 39 additions and 42 deletions

View File

@@ -15,7 +15,6 @@ namespace Content.Client.Singularity
{
[Dependency] private readonly IEntityManager _entityManager = default!;
[Dependency] private readonly IPrototypeManager _prototypeManager = default!;
[Dependency] private readonly IEyeManager _eyeManager = default!;
private const float MaxDist = 15.0f;
@@ -40,7 +39,7 @@ namespace Content.Client.Singularity
{
SingularityQuery(args.Viewport.Eye);
var viewportWB = _eyeManager.GetWorldViewport();
var viewportWB = args.WorldAABB;
// Has to be correctly handled because of the way intensity/falloff transform works so just do it.
_shader?.SetParameter("renderScale", args.Viewport.RenderScale);
foreach (var instance in _singularities.Values)