Hello, I made an animation in stuntman for a test and imported it into UE. I placed it as a standard asset. But when the animation plays, the character moves, but the collider stands still. If I check the enable root motion box, the animation is performed completely in place. How to make the character move and the collider to move with him?
Use an anim notify in the animation to call an event on the character class to move the capsule (teleport).
Hey @mxmodx, @Rev0verDrive gave a great suggestion!
You can also consider creating an animation montage by right clicking on your animation asset that has root motion enabled, navigating to the Create section on the menu that pops up, and selecting the Create AnimMontage option. Then you can use the Play Montage or Play Anim Montage nodes (make sure to plug the Mesh into the In Skeletal Mesh Component pin if you’re gonna use the Play Montage node) to play the animation and you’ll see that the capsule component follows the root bone of the mesh.
Hope this helps!
Thanks, it worked through the installation. Can you tell me more about how to do this through a notify?
Open the animation in the editor. At the bottom there is a section for Notifies, curves etc.
If there aren’t any current notify markers in the track row, left click on the 1, then right click it to rename.
Pause the animation loop. Using the slider move to a point in the animation where you want to set the notify.
Right click in the notify row at the point in time. Add Notify → New Notify.
Name the notify… Hit ENTER for it to accept.
In the character class create a Custom Event.
In the Animation Blueprint (EventGraph) Right click and search for your notify. Add it to the graph.
Next, Using your character reference call the character class event you created.
Your Animation BP should look similar to the following.
From here it’s just setting up the logic on the character class event.
You’re mainly looking at doing a Trace to ground from the Pelvis bone. Take the hit location and use it as the teleport to location for the Capsule.
You can do notifies in Montages as well. Same process as standard animation sequence.
Montage Notify Events fire in the Animation BP like normal.
General rule of thumb is Looping animations will execute in the anim graph via state machine logic.
Action animations like weapon firing/reloading, vaulting etc are handle via Montage. Root motion actions are typically handled via montage.
Case scenario matters.
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.