#include <CharacterGroundConstraint.h>
Game thread side representation of a character ground constraint Modified data from this class will be pushed automatically to the physics thread and available through the FCharacterGroundConstraintHandle class. The FCharacterGroundConstraintProxy class, accessible via GetProxy(), knows about both representations and marshalls the data between them
◆ Base
◆ FCharacterGroundConstraint()
| Chaos::FCharacterGroundConstraint::FCharacterGroundConstraint |
( |
| ) |
|
◆ ~FCharacterGroundConstraint()
| virtual Chaos::FCharacterGroundConstraint::~FCharacterGroundConstraint |
( |
| ) |
|
|
inlineoverridevirtual |
◆ GetAssumedOnGroundHeight()
| FReal Chaos::FCharacterGroundConstraint::GetAssumedOnGroundHeight |
( |
| ) |
const |
|
inline |
◆ GetCharacterParticleProxy()
◆ GetCosMaxWalkableSlopeAngle()
| FReal Chaos::FCharacterGroundConstraint::GetCosMaxWalkableSlopeAngle |
( |
| ) |
const |
|
inline |
◆ GetDampingFactor()
| FReal Chaos::FCharacterGroundConstraint::GetDampingFactor |
( |
| ) |
const |
|
inline |
◆ GetFrictionForceLimit()
| FReal Chaos::FCharacterGroundConstraint::GetFrictionForceLimit |
( |
| ) |
const |
|
inline |
◆ GetGroundDistance()
| FReal Chaos::FCharacterGroundConstraint::GetGroundDistance |
( |
| ) |
const |
|
inline |
◆ GetGroundNormal()
| FVec3 Chaos::FCharacterGroundConstraint::GetGroundNormal |
( |
| ) |
const |
|
inline |
◆ GetGroundParticleProxy()
◆ GetMaxCharacterGroundMassRatio()
| FReal Chaos::FCharacterGroundConstraint::GetMaxCharacterGroundMassRatio |
( |
| ) |
const |
|
inline |
◆ GetMaxWalkableSlopeAngle()
| FReal Chaos::FCharacterGroundConstraint::GetMaxWalkableSlopeAngle |
( |
| ) |
const |
|
inline |
◆ GetMotionTargetMassBias()
| FReal Chaos::FCharacterGroundConstraint::GetMotionTargetMassBias |
( |
| ) |
const |
|
inline |
◆ GetRadialForceLimit()
| FReal Chaos::FCharacterGroundConstraint::GetRadialForceLimit |
( |
| ) |
const |
|
inline |
◆ GetRadialForceMotionTargetScaling()
| FReal Chaos::FCharacterGroundConstraint::GetRadialForceMotionTargetScaling |
( |
| ) |
const |
|
inline |
◆ GetSolverAppliedForce()
| FVector Chaos::FCharacterGroundConstraint::GetSolverAppliedForce |
( |
| ) |
const |
|
inline |
◆ GetSolverAppliedTorque()
| FVector Chaos::FCharacterGroundConstraint::GetSolverAppliedTorque |
( |
| ) |
const |
|
inline |
◆ GetSwingTorqueLimit()
| FReal Chaos::FCharacterGroundConstraint::GetSwingTorqueLimit |
( |
| ) |
const |
|
inline |
◆ GetTargetDeltaFacing()
| FReal Chaos::FCharacterGroundConstraint::GetTargetDeltaFacing |
( |
| ) |
const |
|
inline |
◆ GetTargetDeltaPosition()
| FVec3 Chaos::FCharacterGroundConstraint::GetTargetDeltaPosition |
( |
| ) |
const |
|
inline |
◆ GetTargetHeight()
| FReal Chaos::FCharacterGroundConstraint::GetTargetHeight |
( |
| ) |
const |
|
inline |
◆ GetTwistTorqueLimit()
| FReal Chaos::FCharacterGroundConstraint::GetTwistTorqueLimit |
( |
| ) |
const |
|
inline |
◆ GetUserData()
| void * Chaos::FCharacterGroundConstraint::GetUserData |
( |
| ) |
const |
|
inline |
◆ GetVerticalAxis()
| FVec3 Chaos::FCharacterGroundConstraint::GetVerticalAxis |
( |
| ) |
const |
|
inline |
◆ Init()
◆ SetAssumedOnGroundHeight()
| void Chaos::FCharacterGroundConstraint::SetAssumedOnGroundHeight |
( |
const FReal & |
Value | ) |
|
|
inline |
This is the height below which the character is assumed to be on the ground and can apply force to move. This is useful if the character is slightly off the ground but should still be considered in a locomotion rather than falling state. If this number is set to zero then the constraint can only apply force to move to the motion target if the solver determines that there is a ground reaction force Input should be positive
◆ SetCosMaxWalkableSlopeAngle()
| void Chaos::FCharacterGroundConstraint::SetCosMaxWalkableSlopeAngle |
( |
const FReal & |
Value | ) |
|
|
inline |
◆ SetDampingFactor()
| void Chaos::FCharacterGroundConstraint::SetDampingFactor |
( |
const FReal & |
Value | ) |
|
|
inline |
The damping factor is used to add softness to the vertical constraint between the character and the ground. This can add springiness to landings and slow the rate of step ups. Input should be positive. A value of 0 gives rigid behavior. A value of 1/Dt or above will give maximum softness Units are /T
◆ SetFrictionForceLimit()
| void Chaos::FCharacterGroundConstraint::SetFrictionForceLimit |
( |
const FReal & |
Value | ) |
|
|
inline |
The maximum force that the character can apply in the plane defined by the ground normal to hold the character in place while standing on an unwalkable incline (defined by max walkable slope angle)
◆ SetGroundDistance()
| void Chaos::FCharacterGroundConstraint::SetGroundDistance |
( |
const FReal & |
Value | ) |
|
|
inline |
Vertical distance from the character body to the ground This should be set every frame as the character moves over the ground and is typically measured by performing one or more physics traces Input should be positive
◆ SetGroundNormal()
| void Chaos::FCharacterGroundConstraint::SetGroundNormal |
( |
const FVec3 & |
Normal | ) |
|
|
inline |
Unit normal to the ground plane Input vector is normalized if it is not already a unit vector
◆ SetGroundParticleProxy()
◆ SetMaxCharacterGroundMassRatio()
| void Chaos::FCharacterGroundConstraint::SetMaxCharacterGroundMassRatio |
( |
const FReal & |
Value | ) |
|
|
inline |
Maximum ratio between the character mass and the ground body mass as used by the constraint solver E.g. a value of 2 means that the character can be at most twice as heavy as the ground body and if it is over that the constraint solve will inflate the mass of the ground body to reach a 2:1 ratio This is useful for stability when walking on a light mass. A negative value disables this mass conditioning feature.
◆ SetMaxWalkableSlopeAngle()
| void Chaos::FCharacterGroundConstraint::SetMaxWalkableSlopeAngle |
( |
const FReal & |
Value | ) |
|
|
inline |
The maximum angle of slope that is considered walkable. The slope angle is defined as the angle between the ground normal and vertical axis. If the slope angle is greater than the maximum walkable slope angle the motion target vector is adjusted to stop movement up the slope
◆ SetMotionTarget()
| void Chaos::FCharacterGroundConstraint::SetMotionTarget |
( |
const FVector & |
TargetDeltaPosition, |
|
|
const FReal & |
TargetDeltaFacing |
|
) |
| |
|
inline |
Set both the target delta position and facing angle. This is more efficient than setting them both individually
◆ SetMotionTargetMassBias()
| void Chaos::FCharacterGroundConstraint::SetMotionTargetMassBias |
( |
const FReal & |
Value | ) |
|
|
inline |
This is a fractional value used to scale the ground mass in the motion target constraint. It controls how much tangential force is applied to the ground when the character is moving. 1 means the full reaction force is applied 0 means zero reaction force is applied
◆ SetRadialForceLimit()
| void Chaos::FCharacterGroundConstraint::SetRadialForceLimit |
( |
const FReal & |
Value | ) |
|
|
inline |
The maximum force that the character can apply in the plane defined by the ground normal to move the character to its target position (or hold the character in place if no target delta position is set).
◆ SetRadialForceMotionTargetScaling()
| void Chaos::FCharacterGroundConstraint::SetRadialForceMotionTargetScaling |
( |
const FReal & |
Value | ) |
|
|
inline |
This is a fractional value used to scale the radial force so that the character can achieve the motion target 1 means full scaling is applied and the character will always be able to achieve the motion target 0 means no scaling is applied to the radial force limit
◆ SetSwingTorqueLimit()
| void Chaos::FCharacterGroundConstraint::SetSwingTorqueLimit |
( |
const FReal & |
Value | ) |
|
|
inline |
The maximum torque that the character can apply about the non vertical axes to keep the character upright
◆ SetTargetDeltaFacing()
| void Chaos::FCharacterGroundConstraint::SetTargetDeltaFacing |
( |
const FReal & |
Value | ) |
|
|
inline |
Set the target orientation change about the vertical axis. This is used to turn the character when it is on the ground. The solver will do this by applying a torque if the character is considered to be on the ground and the torque required is less than or equal to the torque limit. For orientation change off the ground, e.g. in air steering, set an angular velocity or impulse on the character body directly. This should be set every frame for a locomoting character, and the value is typically controlled either from a character movement model or from root motion extracted from an animation sequence.
◆ SetTargetDeltaPosition()
| void Chaos::FCharacterGroundConstraint::SetTargetDeltaPosition |
( |
const FVec3 & |
Value | ) |
|
|
inline |
Set the target change in position for the character. This is used to move the character along the ground, and this target will be clamped to the ground plane. The solver will apply a force to move the character to the desired position as long as the character is considered to be on the ground and the force required is less than or equal to the radial force limit. For motion off of the ground, e.g. jumping, set a velocity or impulse on the character body directly. This should be set every frame for a locomoting character, and the value is typically controlled either from a character movement model or from root motion extracted from an animation sequence.
◆ SetTargetHeight()
| void Chaos::FCharacterGroundConstraint::SetTargetHeight |
( |
const FReal & |
Value | ) |
|
|
inline |
Target vertical distance from the character body to the ground If the ground distance is smaller than this number the constraint will try to fix up the error to keep the character at the target height Input should be positive
◆ SetTwistTorqueLimit()
| void Chaos::FCharacterGroundConstraint::SetTwistTorqueLimit |
( |
const FReal & |
Value | ) |
|
|
inline |
The maximum torque that the character can apply about the vertical axis to rotate the character to its target facing direction (or hold the character in place if no target delta facing is set).
◆ SetUserData()
| void Chaos::FCharacterGroundConstraint::SetUserData |
( |
void * |
Value | ) |
|
|
inline |
◆ SetVerticalAxis()
| void Chaos::FCharacterGroundConstraint::SetVerticalAxis |
( |
const FVec3 & |
Axis | ) |
|
|
inline |
Unit vector defining the character up direction Input vector is normalized if it is not already a unit vector
◆ FCharacterGroundConstraintProxy
The documentation for this class was generated from the following files: