RealDocs

UAnimInstance::BlueprintThreadSafeUpdateAnimation

function Engine Blueprint Since 5.0
#include "Animation/AnimInstance.h"
Access: public Specifiers: virtualUFUNCTIONBlueprintImplementableEventmeta=(BlueprintThreadSafe)

Description

Thread-safe Blueprint event for updating animation variables during parallel evaluation. Use this instead of BlueprintUpdateAnimation for performance-critical variable updates that do not require game-thread-only data, allowing the work to run in parallel with other game thread tasks.

Caveats & Gotchas

  • Only thread-safe Blueprint nodes can be called from this event — accessing UObjects, spawning actors, or calling non-thread-safe functions will cause crashes or undefined behavior. Use Property Access nodes and thread-safe getters only.
  • This event runs during the worker thread animation evaluation phase, not on the game thread. Any data read here must have been copied to thread-safe storage beforehand, typically via NativeUpdateAnimation or BlueprintUpdateAnimation.

Signature

virtual void BlueprintThreadSafeUpdateAnimation(float DeltaTime)

Parameters

Name Type Description Default
DeltaTime float Time in seconds since the last animation update.

Return Type

void

Example

Thread-safe locomotion update C++
// In Animation Blueprint:
// 1. Override BlueprintThreadSafeUpdateAnimation
// 2. Use Property Access to read cached velocity/direction
// 3. Compute blend weights without touching game objects

// C++ equivalent using NativeThreadSafeUpdateAnimation:
void UMyAnimInstance::NativeThreadSafeUpdateAnimation(float DeltaSeconds)
{
    Super::NativeThreadSafeUpdateAnimation(DeltaSeconds);
    // Only access thread-safe cached data here
    Speed = CachedVelocity.Size();
    bShouldMove = Speed > 3.0f;
}

Version History

Introduced in: 5.0

Version Status Notes
5.6 stable

Feedback

Was this helpful?

Suggest an edit

Select a field above to begin editing.