refactor: renamed primitives

This commit is contained in:
2025-03-17 21:54:43 +03:00
parent 62b43025b9
commit 9ecf0b900f
9 changed files with 120 additions and 123 deletions

View File

@@ -5,13 +5,13 @@ namespace Syntriax.Engine.Physics2D;
public class Collider2DShapeBehaviour : Collider2DBehaviourBase, IShapeCollider2D
{
public Shape ShapeWorld { get => _shapeWorld; protected set => _shapeWorld = value; }
public Shape ShapeLocal { get; set; } = Shape.Box;
public Shape2D ShapeWorld { get => _shapeWorld; protected set => _shapeWorld = value; }
public Shape2D ShapeLocal { get; set; } = Shape2D.Box;
private Shape _shapeWorld = Shape.Box.CreateCopy();
private Shape2D _shapeWorld = Shape2D.Box.CreateCopy();
public override void CalculateCollider() => Transform.TransformShape(ShapeLocal, ref _shapeWorld);
public Collider2DShapeBehaviour() { }
public Collider2DShapeBehaviour(Shape shape) => ShapeLocal = shape;
public Collider2DShapeBehaviour(Shape2D shape) => ShapeLocal = shape;
}