3 - Setting up the Anim Graph
In this step, we set up our AnimGraph to handle the blending of our AnimMontage and the movement pose from our State Machine.
In the Content/AnimStarterPack, open the UE4ASP_HeroTPP_AnimBlueprint Animation Blueprint.
Inside the MyBlueprint window, open the AnimGraph.
Drag off the Locomotion State Machine and search for and add New Save cached pose.
Here we are getting the resulting pose from our Locomotion State Machine and storing it in a cached pose that we can use elsewhere.
Give the cached pose a name by pressing F2 on the node such as LocomotionCache.
Right-click in the graph and add the Use cached pose 'LocomotionCache' (or whatever you named the cached pose).
Drag off the Use cached pose node and search for and add the Layered blend per bone node.
The Layered Blend Per Bone node will allow us to blend animations together from a specified bone on the Skeleton.
Copy/Paste the Use cached pose 'LocomotionCache' node, then drag off it and add the Slot 'DefaultSlot' node.
In the Settings for the Slot node, click the dropdown menu and select DefaultGroup.UpperBody.
When an Animation Montage that uses this slot is called to play, it will now be called inside our AnimGraph.
Connect the Slot to the Blend Poses 0 pin on the Layered blend per bone node, then connect the out to the Result and Compile.
Our AnimGraph is complete, but we still need to modify some settings on the Layered blend per bone node to finish up which we will do next.