diff --git a/Engine.Physics2D/Primitives/Shape.cs b/Engine.Physics2D/Primitives/Shape.cs index dc9e2aa..6b74d49 100644 --- a/Engine.Physics2D/Primitives/Shape.cs +++ b/Engine.Physics2D/Primitives/Shape.cs @@ -1,4 +1,3 @@ -using System; using System.Collections; using System.Collections.Generic; @@ -9,7 +8,7 @@ namespace Syntriax.Engine.Physics2D.Primitives; public record Shape(IList Vertices) : IEnumerable { - public Vector2D this[Index index] => Vertices[index]; + public Vector2D this[System.Index index] => Vertices[index]; public static Shape CreateCopy(Shape shape) => new(new List(shape.Vertices)); @@ -20,15 +19,15 @@ public record Shape(IList Vertices) : IEnumerable foreach (Vector2D point in shape.Vertices) { - minX = MathF.Min(minX, point.X); - minY = MathF.Min(minY, point.Y); - maxX = MathF.Max(maxX, point.X); - maxY = MathF.Max(maxY, point.Y); + minX = Math.Min(minX, point.X); + minY = Math.Min(minY, point.Y); + maxX = Math.Max(maxX, point.X); + maxY = Math.Max(maxY, point.Y); } float dx = maxX - minX; float dy = maxY - minY; - float deltaMax = MathF.Max(dx, dy); + float deltaMax = Math.Max(dx, dy); float midX = (minX + maxX) / 2; float midY = (minY + maxY) / 2;