Pass world position transform data from sequencer into control rig?

I have a skelmesh of a car, made a control rig with a root control on the root bone. When root translates, the wheels auto rotate, and when root rotates, the wheels auto rotate. All working great in viewports. Working great in sequencer if I manually keyframe the root control.

But it’s a car, I want to animate it following a spline path. Made a rig rail, attached the skelMesh (with the control rig component attached in sequencer. you can’t attach anything other than the top level mesh or bp). Technically the root bone is parented to mesh which is now parented to the rail mount, and thus 0 0 0, and thus no more control rig animation.

This was the case in the unreal’s googly eyes tutorial, they literally manually animated the root after attaching the whole BP to the thirdperson head in sequencer. It worked in gameplay, but not sequencer. He just skimmed over this fact, but like… uhhh wait go back, what are you doing?!

That CANT really be it? There must be a way to get the world position of something animated in sequencer and pass it into the control rig, surely? SURELY? As it is, it doesn’t seem like control rig is useful for linear sequencer animation then? It’s only method of animation is hard core straight up keyframes on controls? Like ya, it can do that, but it really closes the doors to the millions of other ways people can animate…

Please tell me I’m wrong! I’ve been slamming into this problem for 2 weeks now!

2 Likes

I’m having the exact same issue. Anyone know how to feed the sequencer transform that attaches to a path into the CtrlRig blueprint?

I should have updated here, I did end up solving this (and the googly eyes tutorial too) but months ago, so can’t speak confidently about this… Memory is junk …

I think the jist was you’re essentially dragging around your physics based rig by attaching it to an empty actor. That actor is then attached to your moving other object / rig rail.
You can attach it using the “make component reference”:

Control Rig Component | Unreal Engine Documentation.

Here are my notes I wrote a few months ago, in ue5 preview, your mileage may vary. Update here if it works or doesn’t and/ or you fix it or improve it or make it clearer! :slight_smile:

ATTACH CONTROL RIG TO ANOTHER OBJECT
In control rig, before all the foward solve crap, before root, if root is where it starts (make an empty root that does nothing, then if root moves all make that “body” or whatever and foward solve starts there), add a space. So Root (does nothing) / carspace / body_root > foward solve the rest.
At same level as root (so world), add another control called “inputControl”.
Also add a variable “Follow” with boolean eye on.

In rig graph, sequence a) branch, condition “get follow”, true: Set Transform - Space. Type Space, name is carspace, global space, propagate to children on, and get transform control inputControl, global space.

Sequence B goes to the rest of the foward solve.

In a actor blueprint, add skeletal mesh (add your preview mesh youve set up the rig on), and control rig (choose it) and both are at default scene root. Make 2 variables: Follow, boolean, eye on, and AttachActor, actor, eye on.
Construction script: add mapped skeletal mesh, your mesh and rig.
Then drag in “get AttachActor”, into node MakeComponentReference. Into Make ControlRigComponentMappedElement: -1, none, control, element name is “inputControl”, direction input, space World Space. Into Make Array, then Add Mapped Elements, target is control rig.

Event Graph:
on Pre Fowards Solve control rig, component to get control rig, cast to control rig name, as control rig set Follow, and drag in the bp’s follow and hook it in.

Make an empty actor, attach it to whatever (ex. in sequencer, a camerarig rail) using attach. Drag in the BP you made, check on Follow and type in name of the empty actor.

Your bp follows the empty actor. The empty actor follows the rail.

2 Likes

I ended up using a node in the Control Rig that converts to world space. I forget the exact name but if you do a search for world in the node list, of the control rig, it should be there.

1 Like

Hi man, I am in sturggle right now of making the same rig. But I even can’t make it wheels rotate automatically in Control Rig blueprint. Can you please share how you did it? I wrapped my head around with this and can’t get the results :frowning:

1 Like

Hi man, how did you manage to transform this worl transform in local, so that wheels dont rotate in different directions in case of changing the direction?

Check the project Car Configurator blueprint. It has an auto wheel rotation setup there. I managed to adapt it to my setup.

2 Likes

Hi @parakyl, do you know how to send sequencer’s DefautSlot animations into UE5’s control rig? My sequencer animations stop playing when I add: On Pre Initialize → Add Mapped Skeletal Mesh.

Um, not in bp… I’m massively not an expert. A clue maybe: I know in sequencer the way that works is you add your character bp but then delete all control rigs and controls and you’re just left with animation and transform. You then pick an animation, then right click bake to control rig. That bakes that animation into the rig’s controls using I assume the backwards solve part of the rig. And from there you can add an additive track and modify the animation further.

I know that doesn’t answer you at all, but was thinking maybe the way you want it is somewhat similar. You’re trying to add the rig on top of the animations but really it’s the reverse, you gotta bake the animation into the controls.

Sorry I can’t help further.

As for the car rig stuff, I’ll open it up and rummage again once the current challenge is done using up all my time lol.

Thanks, yes I used the bake method in the past, unfortunately in this case I need to be able to reuse the same animation over and over with minor control rig adjustments. The funny thing is that I can make it work if I add the control rig in sequencer but not is I add it in the BP