FORUMS: list search recent posts

Gravity w/ Markers

COW Forums : Adobe After Effects Expressions

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
NspktaGagt
Gravity w/ Markers
on Nov 5, 2007 at 9:27:54 pm

Hi All,

I'm looking for a way to simulate gravity turning on. After a few seconds of animation, where objects float in zero-g, all the sudden gravity is introduced and the objects fall off the screen. I tried keyframing this but I can't figure out the velocity of the objects. I would imagine that this can be accomplished by linking gravity properties to markers or map them to time. Any ideas?


Return to posts index

Dan Ebberts
Re: Gravity w/ Markers
on Nov 6, 2007 at 12:12:43 am

Give this a try:

g = 1000; // gravitational constant

if (marker.numKeys > 0 && time > marker.key(1).time){
t = time - marker.key(1).time;
y = g*t*t/2;
value + [0,y]
}else{
value
}


Dan


Return to posts index

NspktaGagt
Re: Gravity w/ Markers
on Nov 6, 2007 at 3:19:28 pm

Thanks Dan! Does the trick as usual.


Return to posts index


Russell Cox
Re: Gravity w/ Markers
on Aug 5, 2010 at 2:07:01 am

I'm trying to accomplish a similar effect but I put this expression in my position layer and it's not working, does it need a dummy control layer or a slider control? How do I control when the gravity effect occurs?


Return to posts index

Dan Ebberts
Re: Gravity w/ Markers
on Aug 5, 2010 at 2:55:12 am

Just put a layer marker wherever you want it to start falling.

Dan



Return to posts index

Russell Cox
Re: Gravity w/ Markers
on Aug 5, 2010 at 12:31:21 pm

Sorry, it's still not working. Let me review; alt click on stopwatch in static text layer, paste expression, click on keyframe marker. Preview and nothing happens. What am I missing?


Return to posts index


Russell Cox
Re: Gravity w/ Markers
on Aug 5, 2010 at 1:17:25 pm

Got it! First time using expressions triggered by markers, thought it was triggered by a keyframe. Thanks for your help.


Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2019 CreativeCOW.net All Rights Reserved
[TOP]