Hi There!,
I’ve been racking my brain for days trying to come up with a solution. The idea is that when a flashlight shines on the Pawn it freezes its movement and current animation in place. Upon the light not shining on the Pawn, it resumes its movement and randomizes to another animation and continues going.
However I cannot get the animation to resume! Any thoughts on what i’m doing wrong? I’ve played around with state machines, i’ve done play montages, now i’m back to the basics of playing an animation and going from there
I’ve included the State Machine and the Blueprint from my Flashlight which is attached to FirstPerson Blueprint.
FirstPerson BP
State Machine
State MachineBP
Hi!
Are you familiar with Animation Pose Snapshots?
When the light shines on your Pawn and it freezes, create an Animation Pose Snapshot.
Blueprint is called “Save Pose Snapshot”. Target is AnimInstance.
more details here: Animation Pose Snapshot in Unreal Engine | Unreal Engine 5.1 Documentation
When the pawn continues with a certain animation, the animation BP can smoothly blend from the frozen Snapshot to any other animation.
In the AnimGraph is a node “Pose Snapshot”. Give it the snapshot name under which you saved it earlier.
A bool that holds the info if the animation currently should be frozen or not can be used to control blending with regular animation by using “Blend Poses by Bool”.
One example can be seen here:
Animation Pose Snapshot | Live Training,
Cheers!
1 Like
Thank you. Did not know about this!
1 Like