DUIK Bassel Walk Cycle Mover
Hi there!
For everybody who uses DUIK Bassel walk cycle and don't want to move the character comp by hand as the character walks, here is the expression:
iniX = value[0];
myframe = timeToFrames(time);
skal = transform.scale[0]/100;
mycomp = thisLayer.source.name;
myTime = sourceTime(time);
for (n = 0; n <= myframe; n++){
timeback = thisComp.frameDuration * n;
step = comp(mycomp).layer("C | Walk Cycle").effect("Walk Cycle")("Step amplitude (cm)").valueAtTime(myTime - timeback);
stepperframe = step / (comp(mycomp).layer("C | Walk Cycle").effect("Walk Cycle")("Cycle duration (f)") / 2);
iniX += stepperframe;
}
myX = iniX * skal;
[myX ,value[1]];
Apply it to the position of the character comp. The final structur should look like this:
character comp -> Position -> this Expression
|
|_ character layers, DUIK rig, controllers, walk cycle controller
The code is easy and straight forward, but works with keyframed "general motion" in the walk cycle controller, time shifted character comp, scaling in every dimension and every direction of walking.
Feel free to use, spread, edit.
Cheers,
Martin
