Functions for solving planes and clipping vectors.
More...
|
static unsafe PlaneSolverResult | SolvePlanes (in Vec2 targetDelta, CollisionPlane[] planes) |
| Solves the position of a mover that satisfies the given collision planes.
|
|
static unsafe PlaneSolverResult | SolvePlanes (in Vec2 targetDelta, CollisionPlane[] planes, int planeCount) |
| Solves the position of a mover that satisfies the given collision planes.
|
|
static unsafe Vec2 | ClipVector (in Vec2 vector, CollisionPlane[] planes) |
| Clips the velocity against the given collision planes. Planes with zero push or clipVelocity set to false are skipped.
|
|
static unsafe Vec2 | ClipVector (in Vec2 vector, CollisionPlane[] planes, int planeCount) |
| Clips the velocity against the given collision planes. Planes with zero push or clipVelocity set to false are skipped.
|
|
Functions for solving planes and clipping vectors.
◆ ClipVector() [1/2]
static unsafe Vec2 Box2D.Character_Movement.Mover.ClipVector |
( |
in Vec2 |
vector, |
|
|
CollisionPlane[] |
planes |
|
) |
| |
|
inlinestatic |
Clips the velocity against the given collision planes. Planes with zero push or clipVelocity set to false are skipped.
- Parameters
-
vector | The vector to clip |
planes | The collision planes |
- Returns
- The clipped vector
- Exceptions
-
ArgumentNullException | The planes array is null or empty |
◆ ClipVector() [2/2]
static unsafe Vec2 Box2D.Character_Movement.Mover.ClipVector |
( |
in Vec2 |
vector, |
|
|
CollisionPlane[] |
planes, |
|
|
int |
planeCount |
|
) |
| |
|
inlinestatic |
Clips the velocity against the given collision planes. Planes with zero push or clipVelocity set to false are skipped.
- Parameters
-
vector | The vector to clip |
planes | The collision planes |
planeCount | The number of planes to use |
- Returns
- The clipped vector
- Exceptions
-
ArgumentNullException | The planes array is null or empty |
◆ SolvePlanes() [1/2]
Solves the position of a mover that satisfies the given collision planes.
- Parameters
-
targetDelta | The desired movement from the position used to generate the collision planes |
planes | The collision planes |
- Returns
- The result of the plane solver
- Exceptions
-
ArgumentNullException | The planes array is null or empty |
◆ SolvePlanes() [2/2]
Solves the position of a mover that satisfies the given collision planes.
- Parameters
-
targetDelta | The desired movement from the position used to generate the collision planes |
planes | The collision planes |
planeCount | The number of planes to use |
- Returns
- The result of the plane solver
- Exceptions
-
ArgumentNullException | The planes array is null or empty |
The documentation for this class was generated from the following files:
- src/Box2DBindings/Collision/Character Movement/Mover.cs
- src/Box2DBindings/Collision/Character Movement/Mover_Externs.cs