PositionSolver

Package: Libraries.Game.Physics · Inherits from: Libraries.Language.Object

This class contains variables and actions to help solving for the position constraint. This class is used by the CollisionSolver2D class.

Actions

GetNormal()

This action returns the normal vector of this collision.

Returns

Libraries.Compute.Vector2: the normal vector of this collision.

GetPoint()

This action returns the clipping point of this collision.

Returns

Libraries.Compute.Vector2: the clipping point of this collision.

GetSeparation()

This action returns the minimum distance between the two objects colliding.

Returns

number: the minimum distance between the two objects colliding.

Initialize(Libraries.Game.Physics.CollisionPositionConstraint pc, Libraries.Game.Collision.PhysicsPosition2D xfA, Libraries.Game.Collision.PhysicsPosition2D xfB, integer index)

This action initializes the variables stored inside this class.

Parameters

Inherited Actions

3 actions from Libraries.Language.Object