Navigation
API > API/Plugins > API/Plugins/Mover
MovementUtils: a collection of stateless static BP-accessible functions for a variety of movement-related operations
| Name | UMovementUtils |
| Type | class |
| Header File | /Engine/Plugins/Experimental/Mover/Source/Mover/Public/MoveLibrary/MovementUtils.h |
| Include Path | #include "MoveLibrary/MovementUtils.h" |
Syntax
UCLASS (MinimalAPI)
class UMovementUtils : public UBlueprintFunctionLibrary
Inheritance Hierarchy
- UObjectBase → UObjectBaseUtility → UObject → UBlueprintFunctionLibrary → UMovementUtils
Functions
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static FRotator ApplyAngularVelocity
(
const FRotator& StartingOrient, |
Applies a desired angular velocity to a starting rotator over time. | MoveLibrary/MovementUtils.h |
|
static FQuat ApplyAngularVelocityToQuat
(
const FQuat& StartingOrient, |
Applies a desired angular velocity to a starting quaternion over time. | MoveLibrary/MovementUtils.h |
|
static FRotator ApplyAngularVelocityToRotator
(
const FRotator& StartingOrient, |
Applies a desired angular velocity to a starting rotator over time. | MoveLibrary/MovementUtils.h |
|
static FRotator ApplyGravityToOrientationIntent
(
const FRotator& IntendedOrientation, |
Converts intended orientation into orientation rotated by out current gravity | MoveLibrary/MovementUtils.h |
|
static bool CanEscapeGravity
(
const FVector& PriorVelocity, |
Checks whether a given velocity is strong enough to lift off against gravity | MoveLibrary/MovementUtils.h |
|
static FRotator ComputeAngularVelocity
(
const FRotator& From, |
Computes the angular velocity needed to change from one orientation to another within a time frame. | MoveLibrary/MovementUtils.h |
|
static FVector ComputeAngularVelocityDegrees
(
const FRotator& From, |
Computes the angular velocity needed to change from one orientation to another within a time frame. | MoveLibrary/MovementUtils.h |
|
static FVector ComputeCombinedVelocity
(
const FComputeCombinedVelocityParams& InParams |
Returns new velocity based on previous state, movement intent, movement mode's influence and movement settings | MoveLibrary/MovementUtils.h |
|
static FVector ComputeDirectionIntent
(
const FVector& MoveInput, |
Computes the directional movement intent based on input vector and associated type | MoveLibrary/MovementUtils.h |
|
static FVector ComputePenetrationAdjustment
(
const FHitResult& Hit |
Returns a movement step that should get the subject of the hit result out of an initial penetration condition | MoveLibrary/MovementUtils.h | |
static FVector ComputeSlideDelta
(
const FMovingComponentSet& MovingComps, |
Returns an alternative move delta to slide along a surface, based on parameters describing a blocked attempted move | MoveLibrary/MovementUtils.h |
|
static FVector ComputeTwoWallAdjustedDelta
(
const FMovingComponentSet& MovingComps, |
Returns an alternative move delta when we are in contact with 2 surfaces | MoveLibrary/MovementUtils.h | |
static FVector ComputeVelocity
(
const FComputeVelocityParams& InParams |
Returns new ground-based velocity (worldspace) based on previous state, movement intent (worldspace), and movement settings | MoveLibrary/MovementUtils.h |
|
static FVector ComputeVelocityFromGravity
(
const FVector& GravityAccel, |
Returns velocity (units per second) contributed by gravitational acceleration over a given time | MoveLibrary/MovementUtils.h |
|
static FVector ComputeVelocityFromPositions
(
const FVector& FromPos, |
Computes velocity based on start and end positions over time | MoveLibrary/MovementUtils.h |
|
static FVector ConstrainToPlane
(
const FVector& Vector, |
Ensures input Vector (typically a velocity, acceleration, or move delta) is limited to a movement plane. | MoveLibrary/MovementUtils.h |
|
static FVector DeduceUpDirectionFromGravity
(
const FVector& GravityAcceleration |
Returns the up direction deduced from gravity acceleration, but defaults to mover constants up direction if zero | MoveLibrary/MovementUtils.h |
|
static bool FindTeleportSpot
(
const UMoverComponent* MoverComp, |
Try to find an acceptable non-colliding location to place TestActor as close to possible to TestLocation. | MoveLibrary/MovementUtils.h |
|
static FVector GetGravityVerticalComponent
(
const FVector& Vector, |
Returns the component of the vector in the gravity-space vertical direction. | MoveLibrary/MovementUtils.h |
|
static const ComponentType * GetOriginalComponentType
(
const AActor* MoverCompOwner |
Gets CDO component type - useful for getting original values. | MoveLibrary/MovementUtils.h | |
static void InitCollisionParams
(
const UPrimitiveComponent* UpdatedPrimitive, |
MoveLibrary/MovementUtils.h | ||
static bool IsAngularVelocityZero
(
const FRotator& AngularVelocity |
Returns whether this rotator representing angular velocity has any non-zero values. | MoveLibrary/MovementUtils.h |
|
static bool IsExceedingMaxSpeed
(
const FVector& Velocity, |
Checks whether a given velocity is exceeding a maximum speed, with some leeway to account for numeric imprecision | MoveLibrary/MovementUtils.h |
|
static bool OverlapTest
(
const USceneComponent* UpdatedComponent, |
MoveLibrary/MovementUtils.h | ||
static FVector ProjectToGravityFloor
(
const FVector& Vector, |
Project a vector onto the floor defined by the gravity direction. | MoveLibrary/MovementUtils.h |
|
static void SetGravityVerticalComponent
(
FVector& Vector, |
Set the vertical component of the vector to the given value in the gravity-space vertical direction. | MoveLibrary/MovementUtils.h | |
static bool TestEncroachment
(
const UMoverComponent* MoverComp, |
Returns whether MoverComp's Actor would encroach at TestLocation on something that blocks it. | MoveLibrary/MovementUtils.h |
|
static bool TestEncroachment_Internal
(
const UWorld* World, |
Internal function for testing whether a Mover actor would encroach at a test location. | MoveLibrary/MovementUtils.h | |
static bool TestEncroachmentAndAdjust
(
const UMoverComponent* MoverComp, |
Returns whether MoverComp's Actor would encroach at TestLocation on something that blocks it. | MoveLibrary/MovementUtils.h |
|
static bool TestEncroachmentWithAdjustment_Internal
(
const UWorld* World, |
Internal function for testing whether a Mover actor would encroach at a test location, and computes a proposed adjustment where they won't encroach (if found). | MoveLibrary/MovementUtils.h | |
static bool TryMoveToResolvePenetration
(
const FMovingComponentSet& MovingComps, |
Attempts to move out of a situation where the component is stuck in geometry, using a suggested adjustment to start. | MoveLibrary/MovementUtils.h | |
static float TryMoveToSlideAlongSurface
(
const FMovingComponentSet& MovingComps, |
Attempts to move a component along a surface. | MoveLibrary/MovementUtils.h |
|
static float TryMoveToSlideAlongSurfaceNoMovementRecord
(
const FMovingComponentSet& MovingComps, |
Attempts to move a component along a surface. | MoveLibrary/MovementUtils.h |
|
static bool TryMoveUpdatedComponent_Internal
(
const FMovingComponentSet& MovingComps, |
Internal function that other move functions use to perform all actual component movement and retrieve results Note: This function moves the character directly and should only be used if needed. | MoveLibrary/MovementUtils.h | |
static float TrySafeMoveAndSlideUpdatedComponent
(
const FMovingComponentSet& MovingComps, |
Attempts to move a component and resolve any penetration issues with the proposed move Delta. | MoveLibrary/MovementUtils.h |
|
static float TrySafeMoveAndSlideUpdatedComponentNoMovementRecord
(
const FMovingComponentSet& MovingComps, |
Attempts to move a component and resolve any penetration issues with the proposed move Delta. | MoveLibrary/MovementUtils.h |
|
static bool TrySafeMoveUpdatedComponent
(
const FMovingComponentSet& MovingComps, |
Attempts to move a component and resolve any penetration issues with the proposed move Delta Note: This function takes a movement record that collects moves applied to the actor see @FMovementRecord | MoveLibrary/MovementUtils.h |
|
static bool TrySafeMoveUpdatedComponentNoMovementRecord
(
const FMovingComponentSet& MovingComps, |
Attempts to move a component and resolve any penetration issues with the proposed move Delta Note: This function doesn't update a movement record so velocity should be gathered/set using a different method | MoveLibrary/MovementUtils.h |
|