Replace Matrix3 with System.Numerics.Matrix3x2 (#27443)
Replace Matrix3 with Matrix3x2
This commit is contained in:
@@ -39,8 +39,8 @@ public sealed class StatusIconOverlay : Overlay
|
||||
var eyeRot = args.Viewport.Eye?.Rotation ?? default;
|
||||
|
||||
var xformQuery = _entity.GetEntityQuery<TransformComponent>();
|
||||
var scaleMatrix = Matrix3.CreateScale(new Vector2(1, 1));
|
||||
var rotationMatrix = Matrix3.CreateRotation(-eyeRot);
|
||||
var scaleMatrix = Matrix3Helpers.CreateScale(new Vector2(1, 1));
|
||||
var rotationMatrix = Matrix3Helpers.CreateRotation(-eyeRot);
|
||||
|
||||
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))
|
||||
@@ -59,9 +59,9 @@ public sealed class StatusIconOverlay : Overlay
|
||||
if (icons.Count == 0)
|
||||
continue;
|
||||
|
||||
var worldMatrix = Matrix3.CreateTranslation(worldPos);
|
||||
Matrix3.Multiply(scaleMatrix, worldMatrix, out var scaledWorld);
|
||||
Matrix3.Multiply(rotationMatrix, scaledWorld, out var matty);
|
||||
var worldMatrix = Matrix3Helpers.CreateTranslation(worldPos);
|
||||
var scaledWorld = Matrix3x2.Multiply(scaleMatrix, worldMatrix);
|
||||
var matty = Matrix3x2.Multiply(rotationMatrix, scaledWorld);
|
||||
handle.SetTransform(matty);
|
||||
|
||||
var countL = 0;
|
||||
|
||||
Reference in New Issue
Block a user