Revert "make status icons unshaded (#18974)"
This reverts commit 23ad53c1e0.
This commit is contained in:
@@ -4,19 +4,16 @@ using Robust.Client.GameObjects;
|
|||||||
using Robust.Client.Graphics;
|
using Robust.Client.Graphics;
|
||||||
using Robust.Shared.Enums;
|
using Robust.Shared.Enums;
|
||||||
using System.Numerics;
|
using System.Numerics;
|
||||||
using Robust.Shared.Prototypes;
|
|
||||||
|
|
||||||
namespace Content.Client.StatusIcon;
|
namespace Content.Client.StatusIcon;
|
||||||
|
|
||||||
public sealed class StatusIconOverlay : Overlay
|
public sealed class StatusIconOverlay : Overlay
|
||||||
{
|
{
|
||||||
[Dependency] private readonly IEntityManager _entity = default!;
|
[Dependency] private readonly IEntityManager _entity = default!;
|
||||||
[Dependency] private readonly IPrototypeManager _prototype = default!;
|
|
||||||
|
|
||||||
private readonly SpriteSystem _sprite;
|
private readonly SpriteSystem _sprite;
|
||||||
private readonly TransformSystem _transform;
|
private readonly TransformSystem _transform;
|
||||||
private readonly StatusIconSystem _statusIcon;
|
private readonly StatusIconSystem _statusIcon;
|
||||||
private readonly ShaderInstance _shader;
|
|
||||||
|
|
||||||
public override OverlaySpace Space => OverlaySpace.WorldSpaceBelowFOV;
|
public override OverlaySpace Space => OverlaySpace.WorldSpaceBelowFOV;
|
||||||
|
|
||||||
@@ -27,7 +24,6 @@ public sealed class StatusIconOverlay : Overlay
|
|||||||
_sprite = _entity.System<SpriteSystem>();
|
_sprite = _entity.System<SpriteSystem>();
|
||||||
_transform = _entity.System<TransformSystem>();
|
_transform = _entity.System<TransformSystem>();
|
||||||
_statusIcon = _entity.System<StatusIconSystem>();
|
_statusIcon = _entity.System<StatusIconSystem>();
|
||||||
_shader = _prototype.Index<ShaderPrototype>("unshaded").Instance();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override void Draw(in OverlayDrawArgs args)
|
protected override void Draw(in OverlayDrawArgs args)
|
||||||
@@ -40,8 +36,6 @@ public sealed class StatusIconOverlay : Overlay
|
|||||||
var scaleMatrix = Matrix3.CreateScale(new Vector2(1, 1));
|
var scaleMatrix = Matrix3.CreateScale(new Vector2(1, 1));
|
||||||
var rotationMatrix = Matrix3.CreateRotation(-eyeRot);
|
var rotationMatrix = Matrix3.CreateRotation(-eyeRot);
|
||||||
|
|
||||||
handle.UseShader(_shader);
|
|
||||||
|
|
||||||
var query = _entity.AllEntityQueryEnumerator<StatusIconComponent, SpriteComponent, TransformComponent, MetaDataComponent>();
|
var query = _entity.AllEntityQueryEnumerator<StatusIconComponent, SpriteComponent, TransformComponent, MetaDataComponent>();
|
||||||
while (query.MoveNext(out var uid, out var comp, out var sprite, out var xform, out var meta))
|
while (query.MoveNext(out var uid, out var comp, out var sprite, out var xform, out var meta))
|
||||||
{
|
{
|
||||||
@@ -105,7 +99,5 @@ public sealed class StatusIconOverlay : Overlay
|
|||||||
handle.DrawTexture(texture, position);
|
handle.DrawTexture(texture, position);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
handle.UseShader(null);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user