PhysicsAPI reference
Struct MoveContact
Namespace: MicroEngine.Physics
Assembly: MicroEngine.Physics.dll
Guide: Physics worlds
A surface a moving body touched (Contacts).
public readonly struct MoveContact : IEquatable<MoveContact>Implements
Constructors
MoveContact(ShapeId, EntityId, Vector2)
A surface a moving body touched (Contacts).
public MoveContact(ShapeId Shape, EntityId Owner, Vector2 Normal)Parameters
Shape ShapeId
The shape touched.
Owner EntityId
The entity owning that shape’s body.
Normal Vector2
The surface normal, unit length, pointing from the surface towards the moving body.
Properties
Normal
The surface normal, unit length, pointing from the surface towards the moving body.
public Vector2 Normal { get; init; }Property Value
Owner
The entity owning that shape’s body.
public EntityId Owner { get; init; }Property Value
Shape
The shape touched.
public ShapeId Shape { get; init; }Property Value
Methods
Deconstruct(out ShapeId, out EntityId, out Vector2)
public void Deconstruct(out ShapeId Shape, out EntityId Owner, out Vector2 Normal)Parameters
Shape ShapeId
Owner EntityId
Normal Vector2
Equals(object)
public override bool Equals(object obj)Parameters
obj object
Returns
Equals(MoveContact)
public bool Equals(MoveContact other)Parameters
other MoveContact
Returns
GetHashCode()
public override int GetHashCode()Returns
ToString()
public override string ToString()Returns
Operators
operator ==(MoveContact, MoveContact)
public static bool operator ==(MoveContact left, MoveContact right)Parameters
left MoveContact
right MoveContact
Returns
operator !=(MoveContact, MoveContact)
public static bool operator !=(MoveContact left, MoveContact right)Parameters
left MoveContact
right MoveContact