ue-animation-system
Use this skill when working with Unreal Engine animation: AnimInstance, montage playback, blend space, state machine, anim notify, IK, AnimGraph, skeletal mesh, or linked anim graphs. See references/anim-notify-reference.md for notify patterns and references/locomotion-setup.md for locomotion setup.
By quodsoler · 854 installs
npx skills add quodsoler/unreal-engine-skills --skill ue-animation-system
Source repository · Upstream listing
UE Animation System
Target engine: UE 5.8 . APIs below are verified against the 5.8 headers; older forms are listed under "Deprecated — do not use".
Covers the runtime animation path in the Engine module — UAnimInstance , FAnimInstanceProxy , UAnimMontage , UAnimNotify / UAnimNotifyState , curves, blend spaces, anim state machines, linked anim layers and root motion — plus the animation plugins shipped in 5.8 ( PoseSearch , MotionWarping , Chooser , IKRig , ControlRig , BlendStack , OptimusCore , UAF ). Build.cs: Engine for everything under Runtime/Engine/Classes/Animation , AnimGraphRuntime for the helper anim nodes such as FAnimNode LayeredBoneBlend ; plugin module names are listed per row below.
Context
Read .agents/ue project context.md if it exists (module names, conventions, enabled plugins, GAS/networking setup). Do not stop if it is missing.
Identify the area from the request and the codebase. Ask only when two plausible readings would produce different code.
Request is about… Go to
AnimInstance subclass, thread safe update, proxy [AnimInstance and Proxy]( animinstance and proxy)
Playing/stopping montages, section jumps, end callbacks [Montages]( montages)
Notifies, notify states, branching points, notify timing [Anim Notifies]( anim notifies)
Curve values, morph targets, curve metadata [Animation Curves]( animation curves)
Blend spaces, state machines, aim offsets, layered blends [Blend Spaces and State Machines]( blend spaces and state machines)
Linked anim layers, per mode locomotion swapping [Linked Anim Graphs and Layers]( linked anim graphs and layers)
Root motion extraction and modes [Root Motion]( root motion)
Motion matching, warping, IK Rig, Control Rig, deformers [5.8 Animation Plugins]( 58 animation plugins)
AnimInstance and Proxy
UAnimInstance ( Animation/AnimInstance.h ) runs in two phases. Game thread: NativeUpdateAnimation — safe to read gameplay state. Worker thread: NativeThreadSafeUpdateAnimation and blend tree evaluation. Cache gameplay reads on the game thread; read only those cached values on the worker thread.
Verbatim virtuals ( AnimInstance.h:1436 1457 public, :1716 1719 protected):
FAnimInstanceProxy ( Public/Animation/AnimInstanceProxy.h ) is the worker thread data container. Its override points are protected ( :603 669 ):
Reach the proxy with the protected templates GetProxyOnGameThread<T () ( :1746 ) and GetProxyOnAnyThread<T () ( :1769 ).
Query pending update state with NeedsUpdate() ( AnimInstance.h:512 ); the bNeedsUpdate member is deprecated.
Montages
Source: Animation/AnimInstance.h , Animation/AnimMontage.h . Verbatim signatures ( AnimInstance.h:626 796 ):
EMontagePlayReturnType ( AnimInstance.h:70 ) is MontageLength or Duration . Once blend out starts, Montage IsPlaying and Montage IsActive return false and Montage GetIsStopped returns true, even though the pose is still blending ( Stop() removes the instance from ActiveMontagesMap , AnimInstance.cpp:3709 ). Use OnMontageBlendingOut / Montage SetBlendingOutDelegate for blend out start and OnMontageEnded for the end. Delegate types ( AnimInstance.h:79 80 ) are single cast:
For broadcast, use the dynamic multicast members OnMontageStarted , OnMontageEnded and OnMontageBlendingOut ( :758 770 ).
USkeletalMeshComponent ( Components/SkeletalMeshComponent.h ):
PlayAnimation puts the component in single node mode; SetAnimInstanceClass puts it in Animation Blueprint mode. Mixing both on one component silently drops one of them.
Multiplayer: with GAS, drive montages through UAbilityTask PlayMontageAndWait::CreatePlayMontageAndWaitProxy ( GameplayAbilities/Public/Abilities/Tasks/AbilityTask PlayMontageAndWait.h:66 ) — see ue gameplay abilities . Without GAS, replicate the montage choice yourself and call Montage Play from the replication callback; never call it independently per net role.
Anim Notifies
Source: Animation/AnimNotifies/AnimNotify.h , AnimNotifyState.h . Override these exact signatures:
Received Notify ( AnimNotify.h:62 ) and Received NotifyBegin / Received NotifyTick / Received NotifyEnd ( AnimNotifyState.h:45 51 ) are BlueprintImplementableEvent entry points — implement them in Blueprint, never override them in C++.
Montage notify timing is per event: FAnimNotifyEvent::MontageTickType ( Public/Animation/AnimTypes.h:318 ) is EMontageNotifyTickType::Queued (fired at the end of the evaluation phase — the header states it is not suitable for changing sections or montage position) or BranchingPoint (fired as encountered, suitable for section changes). A native notify forces the branching point path by setting bIsNativeBranchingPoint = true in its constructor ( AnimNotify.h:123 , AnimNotifyState.h:108 ).
Bind named montage notifies from outside the AnimInstance with OnPlayMontageNotifyBegin / OnPlayMontageNotifyEnd ( AnimInstance.h:1820 1823 , type FPlayMontageAnimNotifyDelegate ).
See [references/anim notify reference.md](references/anim notify reference.md) for the built in notify catalog, complete custom notify and notify state examples, FAnimNotifyEvent fields and linked instance propagation.
Animation Curves
Curves are addressed by FName in 5.8 — no smart names, no curve UIDs, no mapping lookups.
Per curve flags (does the curve drive a material or a morph target) live in CurveMetaData on the skeleton ( Animation/Skeleton.h:387 467 ): GetCurveMetaData(FName) , AddCurveMetaData(FName CurveName, bool bTransact = true) , GetCurveMetaDataNames(TArray<FName & OutNames) , SetCurveMetaDataMorphTarget(FName CurveName, bool bOverrideMorphTarget) .
Blend Spaces and State Machines
Blend spaces are assets sampled by AnimGraph nodes; drive them from UPROPERTY members the AnimGraph reads.
Asset class Header Use
UBlendSpace Animation/BlendSpace.h:470 Two axis blend, typically Direction x Speed
UBlendSpace1D Animation/BlendSpace1D.h:19 Single axis, typically Speed
UAimOffsetBlendSpace Animation/AimOffsetBlendSpace.h:20 Additive aim poses over a base pose
Axis smoothing is FInterpolationParameter ( BlendSpace.h:80 110 ): InterpolationTime , DampingRatio , MaxSpeed , and InterpolationType of type TEnumAsByte<EFilterInterpolationType — values BSIT Average , BSIT Linear , BSIT Cubic , BSIT EaseInOut , BSIT ExponentialDecay , BSIT SpringDamper ( Engine/EngineTypes.h:1356 ).
Bind native C++ to a compiled state machine from NativeInitializeAnimation ( AnimInstance.h:1461 1473 ):
Query at runtime with GetStateMachineIndex(FName MachineName) ( :1202 ), GetStateMachineInstanceFromName(FName MachineName) ( :1191 ) and GetInstanceStateWeight(int32 MachineIndex, int32 StateIndex) ( :1116 ).
See [references/locomotion setup.md](references/locomotion setup.md) for a full blend space, state machine, layered blend per bone and aim offset setup.
Linked Anim Graphs and Layers
Source: Animation/AnimNode LinkedAnimGraph.h , Animation/AnimNode LinkedAnimLayer.h .
LinkAnimClassLayers(nullptr) restores the default layer implementations. Notify flow across linked instances is set by SetReceiveNotifiesFromLinkedInstances(bool bSet) and SetPropagateNotifiesToLinkedInstances(bool bSet) ( :523 531 ), or per node by bReceiveNotifiesFromLinkedInstances / bPropagateNotifiesToLinkedInstances ( AnimNode LinkedAnimGraph.h:76 80 ). SetUseMainInstanceMontageEvaluationData(bool bSet) ( :537 ) makes linked layers share the main instance's montage evaluation.
Blend the swap with PendingBlendInDuration / PendingBlendOutDuration on the linked node ( AnimNode LinkedAnimGraph.h:60 67 ), or request one from code:
Root Motion
ERootMotionMode::Type ( Animation/AnimEnums.h:27 42 ): NoRootMotionExtraction , IgnoreRootMotion , RootMotionFromEverything , RootMotionFromMontagesOnly . The header marks RootMotionFromEverything as unsuitable for networked multiplayer and RootMotionFromMontagesOnly as the networked choice.
Montage root motion and RootMotionSource are separate systems: the montage path feeds the pose derived delta into the movement component, while RootMotionSource applies scripted movement with no animation attached. Networked prediction, correction and bAllowPhysicsRotationDuringAnimRootMotion ( GameFramework/CharacterMovementComponent.h:1083 ) belong to ue character movement .
5.8 Animation Plugins
Each is disabled by default in the .uproject unless noted; add the module to Build.cs when you use its types.
Plugin / module 5.8 maturity Key types and headers
PoseSearch production FAnimNode MotionMatching ( PoseSearch/AnimNode MotionMatching.h:18 ), UPoseSearchDatabase ( PoseSearch/PoseSearchDatabase.h:502 ); trajectories are FTransformTrajectorySample ( Runtime/Engine/Public/Animation/TrajectoryTypes.h:18 )
Chooser production UChooserTable ( Chooser.h:22 ), UChooserFunctionLibrary ( ChooserFunctionLibrary.h:18 ) — data driven asset selection, commonly feeding motion matching
MotionWarping Beta in 5.8 UMotionWarpingComponent ( MotionWarpingComponent.h:100 ), URootMotionModifier ( RootMotionModifier.h:71 ); rotation offsets use AdditionalRotationOffset ( RootMotionModifier.h:407 )
IKRig production, enabled by default UIKRigDefinition ( Rig/IKRigDefinition.h:206 ), UIKRetargeter ( Retargeter/IKRetargeter.h:70 ) — runtime IK solving and animation retargeting
ControlRig production, enabled by default UControlRig ( ControlRig.h:63 ), FAnimNode ControlRig ( AnimNode ControlRig.h:21 ) — procedural rigs evaluated inside the AnimGraph
BlendStack production FAnimNode BlendStack and FAnimNode BlendStack Standalone ( BlendStack/AnimNode BlendStack.h:272,150 ) — the blend stack motion matching is built on
OptimusCore (Deformer Graph) Beta in 5.8 UOptimusDeformer ( OptimusDeformer.h:132 ) — GPU mesh deformation graphs
UAF Experimental in 5.8 Plugins/Experimental/UAF/UAF , module UAF : UUAFRigVMAsset ( AnimNextRigVMAsset.h:61 ), UUAFComponent ( Component/AnimNextComponent.h:77 ) — the successor animation framework
Deprecated — do not use
Do not emit Use in 5.8 Source
FSmartName , FSmartNameMapping , FSmartNameContainer plain FName curve names UE DEPRECATED(5.8) in Animation/SmartName.h:20,80,121
Skeleton smart name curve tables CurveMetaData accessors on USkeleton UE DEPRECATED(5.7) in Animation/Skeleton.h:505
AnimCurveUID FName curve names UE DEPRECATED(5.7) in Animation/Skeleton.h:384
UAnimInstance::bNeedsUpdate NeedsUpdate() UE DEPRECATED(5.7) in Animation/AnimInstance.h:389
USkeletalMeshComponent::SetAnimClass SetAnimInstanceClass UE DEPRECATED(5.5) in Components/SkeletalMeshComponent.h:1084
USkeletalMeshComponent::AnimCurves member GetAnimCurves() / GetCurveValue() UE DEPRECATED(5.6) in Components/SkeletalMeshComponent.h:470
UAnimSequence::RetargetSourceAsset member GetRetargetSourceAsset / SetRetargetSourceAsset UE DEPRECATED(5.5) in Animation/AnimSequence.h:305
FTrajectorySample FTransformTrajectorySample UE DEPRECATED(5.6) in Public/Animation/MotionTrajectoryTypes.h:10
FPoseSearchQueryTrajectorySample FTransformTrajectorySample UE DEPRECATED(5.6) in PoseSearch/PoseSearchTrajectoryTypes.h:16
FPoseSearchDatabaseSequence , FPoseSearchDatabaseBlendSpace FPoseSearchDatabaseAnimationAsset UE DEPRECATED(5.7) in PoseSearch/PoseSearchDatabase.h:228
EMotionWarpRotationType::OppositeDefault / OppositeFacing AdditionalRotationOffset UE DEPRECATED(5.8) in MotionWarping/RootMotionModifier.h:309,312
FAnimInstanceProxy::GetSlotInertializationRequest