Navigation
API > API/Runtime > API/Runtime/Engine > API/Runtime/Engine/GameFramework
Inheritance Hierarchy
- UObjectBase
- UObjectBaseUtility
- UObject
- UActorComponent
- UMovementComponent
- UNavMovementComponent
- UPawnMovementComponent
- UCharacterMovementComponent
- UFloatingPawnMovement
- USpectatorPawnMovement
References
| Module | Engine |
| Header | /Engine/Source/Runtime/Engine/Classes/GameFramework/NavMovementComponent.h |
| Include | #include "GameFramework/NavMovementComponent.h" |
Syntax
UCLASS (Abstract, Config=Engine, MinimalAPI)
class UNavMovementComponent :
public UMovementComponent ,
public INavMovementInterface
Remarks
NavMovementComponent defines base functionality for MovementComponents that move any 'agent' that may be involved in AI pathfinding.
Variables
| Type | Name | Description | |
|---|---|---|---|
| FMovementProperties | MovementState | Expresses runtime state of character's movement. | |
| FNavAgentProperties | NavAgentProps | Properties that define how the component can move. | |
| FNavMovementProperties | NavMovementProperties |
Constructors
| Type | Name | Description | |
|---|---|---|---|
UNavMovementComponent
(
const FObjectInitializer& ObjectInitializer |
Functions
| Type | Name | Description | |
|---|---|---|---|
| void | Clears fixed braking distance | ||
| FVector | Returns location of controlled actor's "feet" meaning center of bottom of collision bounding box | ||
| FBasedPosition | Returns based location of controlled actor | ||
| FVector | Returns location of controlled actor - meaning center of collision bounding box | ||
| FVector | Returns navigation location of controlled actor | ||
| FTransform | Returns the full world-coordinates transform of the associated scene component (the UpdatedComponent) | ||
| bool | Returns true if component is allowed to jump | ||
| void | SetJumpAllowed
(
bool bAllowed |
Sets whether this component is allowed to jump | |
| void | SetUpdateNavAgentWithOwnersCollisions
(
bool bUpdateWithOwner |
||
| bool |
Overridden from UMovementComponent
| Type | Name | Description | |
|---|---|---|---|
| void | Overridden to also call StopActiveMovement(). |
Overridden from UObject
| Type | Name | Description | |
|---|---|---|---|
| void | Handles reading, writing, and reference collecting using FArchive. |
Overridden from INavMovementInterface
| Type | Name | Description | |
|---|---|---|---|
| bool | Returns true if path following can start | ||
| bool | Check if current move target can be reached right now if positions are matching (e.g. performing scripted move and can't stop) | ||
| FVector | Returns location of controlled actor's "feet" meaning center of bottom of collision bounding box | ||
| FBasedPosition | Returns based location of controlled actor | ||
| FVector | Get forward vector of the object being driven by nav movement | ||
| FVector | GetLocation () |
Returns location of controlled actor - meaning center of collision bounding box | |
| float | Get maximum movement speed of the agent | ||
| FNavAgentProperties & | Returns the NavAgentProps | ||
| const FNavAgentProperties & | Returns the NavAgentProps(const) | ||
| const FNavMovementProperties & | Returns the NavMovementProps(const) | ||
| FNavMovementProperties * | Get Nav movement props struct this component uses | ||
| UObject * | Get the owner of the object consuming nav movement | ||
| IPathFollowingAgentInterface * | Get path following agent this interface uses | ||
| const IPathFollowingAgentInterface * | Get path following agent this interface uses(const) | ||
| void | GetSimpleCollisionCylinder
(
float& CollisionRadius, |
Get axis-aligned cylinder around this actor, used for simple collision checks in nav movement | |
| FVector | Returns collision extents vector for this object, based on GetSimpleCollisionCylinder. | ||
| TObjectPtr< UObject > | Get the component this movement component is updating | ||
| FVector | Get the current velocity of the movement component | ||
| bool | IsCrouching () |
Returns true if currently crouching | |
| bool | IsFalling () |
Returns true if currently falling (not flying, in a non-fluid volume, and not on the ground) | |
| bool | IsFlying () |
Returns true if currently flying (moving through a non-fluid volume without resting on the ground) | |
| bool | Returns true if currently moving on the ground (e.g. walking or driving) | ||
| bool | IsSwimming () |
Returns true if currently swimming (moving through a fluid volume) | |
| void | RequestDirectMove
(
const FVector& MoveVelocity, |
Path following: request new velocity | |
| void | RequestPathMove
(
const FVector& MoveInput |
Path following: request new move input (normal vector = full strength) | |
| void | Resets runtime movement state to character's movement capabilities | ||
| void | SetPathFollowingAgent
(
IPathFollowingAgentInterface* InPathFollowingAgent |
Set the path following agent this interface uses. | |
| void | UpdateNavAgent
(
const UObject& ObjectToUpdateFrom |
Set nav agent properties from an object |
Deprecated Variables
| Type | Name | Description | |
|---|---|---|---|
| uint8: 1 | bStopMovementAbortPaths_DEPRECATED | If set, StopActiveMovement call will abort current path following request | |
| uint8: 1 | bUpdateNavAgentWithOwnersCollision_DEPRECATED | If set to true NavAgentProps' radius and height will be updated with Owner's collision capsule size | |
| uint8: 1 | bUseAccelerationForPaths_DEPRECATED | If set, pathfollowing will control character movement via acceleration values. | |
| uint8: 1 | bUseFixedBrakingDistanceForPaths_DEPRECATED | If set, FixedPathBrakingDistance will be used for path following deceleration | |
| float | FixedPathBrakingDistance_DEPRECATED | Braking distance override used with acceleration driven path following (bUseAccelerationForPaths) |