FAnimNode_Trail

Trail Controller

Choose your operating system:

Windows

macOS

Linux

Inheritance Hierarchy

References

Module

AnimGraphRuntime

Header

/Engine/Source/Runtime/AnimGraphRuntime/Public/BoneControllers/AnimNode_Trail.h

Include

#include "BoneControllers/AnimNode_Trail.h"

Syntax

struct FAnimNode_Trail : public FAnimNode_SkeletalControlBase

Remarks

Trail Controller

Variables

Name Description

Public variable

uint8: 1

 

bActorSpaceFakeVel

Whether 'fake' velocity should be applied in actor or world space.

Public variable

FBoneReference

 

BaseJoint

Base Joint to calculate velocity from. If none, it will use Component's World Transform. .

Public variable

uint8: 1

 

bEditorDebugEnabled

This is used by selection node. Use this transient flag.

Public variable

uint8: 1

 

bEnableDebug

Enable Debug in the PIE. This doesn't work in game

Public variable

uint8: 1

 

bHadValidStrength

Did we have a non-zero ControlStrength last frame.

Public variable

uint8: 1

 

bInvertChainBoneAxis

Invert the direction specified in ChainBoneAxis.

Public variable

uint8: 1

 

bLimitRotation

Limit the amount that a bone can stretch from its ref-pose length.

Public variable

uint8: 1

 

bLimitStretch

Limit the amount that a bone can stretch from its ref-pose length.

Public variable

uint8: 1

 

bReorientParentToChild

Fix up rotation to face child for the parent

Public variable

uint8: 1

 

bShowBaseMotion

Show Base Motion

Public variable

uint8: 1

 

bShowLimit

Show Planar Limits

Public variable

uint8: 1

 

bShowTrailLocation

Show Trail Location

Public variable

uint8: 1

 

bUsePlanarLimit

Whether to evaluate planar limits

Public variable

TEnumAsByte< EA...

 

ChainBoneAxis

Axis of the bones to point along trail.

Public variable

int32

 

ChainLength

Number of bones above the active one in the hierarchy to modify. ChainLength should be at least 2.

Public variable

float

 

DebugLifeTime

Debug Life Time

Public variable

FVector

 

FakeVelocity

'Fake' velocity applied to bones.

Public variable

float

 

LastBoneRotationAnimAlphaBlend

How to set last bone rotation.

Public variable

float

 

MaxDeltaTime

To avoid hitches causing stretch of trail, you can use MaxDeltaTime to clamp the long delta time.

Public variable

FTransform

 

OldBaseTransform

LocalToWorld used last frame, used for building transform between frames.

Public variable

TArray< FPerJoi...

 

PerJointTrailData

Per Joint Trail Set up

Public variable

TArray< FAnimPh...

 

PlanarLimits

List of available planar limits for this node

Public variable

TArray< FColor ...

 

PlaneDebugColors

Public variable

float

 

RelaxationSpeedScale

Public variable

FInputScaleBias...

 

RelaxationSpeedScaleInputProcessor

Public variable

TArray< FRotati...

 

RotationLimits

Public variable

TArray< FVector...

 

RotationOffsets

Public variable

float

 

StretchLimit

If bLimitStretch is true, this indicates how long a bone can stretch beyond its length in the ref-pose.

Public variable

float

 

ThisTimstep

Internal use - we need the timestep to do the relaxation in CalculateNewBoneTransforms.

Public variable

FBoneReference

 

TrailBone

Reference to the active bone in the hierarchy to modify.

Public variable

TArray< FVector...

 

TrailBoneLocations

Component-space locations of the bones from last frame.

Public variable

TArray< FColor ...

 

TrailDebugColors

Debug transient data to draw debug better

Public variable

FRuntimeFloatCu...

 

TrailRelaxationSpeed

How quickly we 'relax' the bones to their animated positions.

Constructors

Name Description

Public function

FAnimNode_Trail()

Functions

Name Description

Public function

void

 

EnsureChainSize()

Public function

void

 

PostLoad()

Overridden from FAnimNode_SkeletalControlBase

Name Description

Public function Virtual

void

 

EvaluateSkeletalControl_AnyThread

(
    FComponentSpacePoseContext& Output,
    TArray< FBoneTransform >& OutBoneT...
)

Evaluate the new component-space transforms for the affected bones.

Public function Virtual

bool

 

IsValidToEvaluate

(
    const USkeleton* Skeleton,
    const FBoneContainer& RequiredBone...
)

Return true if it is valid to Evaluate

Public function Virtual

void

 

UpdateInternal

(
    const FAnimationUpdateContext& Con...
)

Interface for derived skeletal controls to implement use this function to update for skeletal control base

Overridden from FAnimNode_Base

Name Description

Public function Virtual

void

 

GatherDebugData

(
    FNodeDebugData& DebugData
)

Called to gather on-screen debug data. This is called on the game thread.

Public function Virtual

void

 

Initialize_AnyThread

(
    const FAnimationInitializeContext&...
)

Called when the node first runs.

Deprecated Variables

Name Description

Public variable

float

 

TrailBoneRotationBlendAlpha_DEPRECATED

Public variable

float

 

TrailRelaxation_DEPRECATED

How quickly we 'relax' the bones to their animated positions.