Forum Replies Created
-
Hey I just did my research on your problem and came up with a solution.
Following are the steps:
1. Create a text file and place it in D: drive (for ease of access)
2. Add your words in the text file in the following format:
x = ["Courage", "Strength", "Valor", "Dedication", "And So On..."];
3. Save and close the text file.
4. Add Slider Control to your text layer in AE and name it “Change Rate (Speed)”
5. Add the following expression in the Source Text property of your text layer
myPath = "/d/file.txt";
x = $.evalFile (myPath);
rate = time*effect("Change Rate (Speed)")("Slider");
len = x.length;
x[--len];
for(i = 0; i < len; i++)
{
if((rate>=i)&&(rate<(i+1)))
x[i];
}
Hope this solves the issue 🙂
—
Fahd Chishty
Motion Design Artist -
To make respond to keyframes, you need to put values of startVal and endVal by keys.
startVal = key(1);
endVal = key(2);Secondly, to solve the position only problem, I replace the transform.position[0] by value[0]
Or if you want to animate the 2nd value make it [ans, value[1]]freq = 2;
decay = 5;
delay = 0.15;
dur = 0.12;
myDelay = delay;
t = time - (inPoint + myDelay);
startVal = key(1) ;
endVal = key(2);
amp = (endVal - startVal)/dur;
w = freq*Math.PI*2;
ans=endVal + amp*(Math.sin(t*w)*Math.exp(decay*t)/w);
[value[0], ans]—
Fahd Chishty
Motion Design Artist
MotionCue -
You need Collision Detection. Dan Ebberts has done a wonderful job of explaining it and using it
https://www.motionscript.com/design-guide/collision.html—
Fahd Chishty
Motion Design Artist
MotionCue -
Dude! I have spent a lot of time on your problem, trying to solve it by expressions, but since After effects expressions have no way of storing a value, the floor jumps back to initial position once it has gone back with the foot.
I would suggest that you stick with the manual keyframes as they are easier to manipulate. Keyframe your floor to move back as each foot moves back.In terms of expression, maybe Dan Ebberts can help. I raise my hands in defeat.
—
Fahd Chishty
Motion Design Artist
MotionCue -
Do they both use the same Null or are there separate Nulls for both of them each?
—
Fahd Chishty
Motion Design Artist
MotionCue -
Try this.
freq = 2;
decay = 5;
delay = 0.15;
dur = 0.12;
myDelay = delay;
t = time - (inPoint + myDelay);
startVal = 539 ;
endVal = 540;
amp = (endVal - startVal)/dur;
w = freq*Math.PI*2;
ans=endVal + amp*(Math.sin(t*w)*Math.exp(decay*t)/w);
[transform.position[0], ans]—
Fahd Chishty
Motion Design Artist
MotionCue -
Actually when I was working on your problem last night, I thought of that issue too. I will work on it tonight again and then post the modified code.
—
Fahd Chishty
Motion Design Artist
MotionCue -
It may be giving you error because your Null object has a different name. If that is the case then replace “Foot_Controller” with the name your own Null object.
Or you can remove this statement “thisComp.layer(“Foot_Controller”).transform.position[0]” and pickwhip the X position of your controller
—
Fahd Chishty
Motion Design Artist
MotionCue -
Provided that you are using a null object named “Foot Controller” and you want the floor to move back only when that null moves back, the following expression may help you.
Put it in the position of your floor.temp = thisComp.layer("Foot_Controller").transform.position[0];
d=thisComp.frameDuration;
org=transform.position[1];
orgx=transform.position[0];
x=thisComp.layer("Foot_Controller").transform.position.valueAtTime(time-d)[0];if(temp<=x)
{
[temp, org];
}
else
{
[orgx,org];
}
—
Fahd Chishty
Motion Design Artist
MotionCue -
Fahd Chishty
January 20, 2015 at 8:20 pm in reply to: Expression for stroke following a motion path?Look at the explanation of “Create a motion path from a mask, shape, or paint path” on this site: https://helpx.adobe.com/after-effects/using/assorted-animation-tools.html
I think you should create a path first and then make your fly follow that path. You can add dashes and trim path animation to follow the fly.
I am attaching a sample for your ease.
—
Fahd Chishty
Motion Design Artist
MotionCue