How To Start And Stop Wiggle In After Effects At Specific Time

With few lines of additional code to the standard wiggle expression, we can start and stop wiggle effect in After Effects at a specific time.

Wiggle (camera shake) is one of the most common, easy to remember After Effects expression and is applied to the position property of a layer. wiggle(x,y) where x and y are in digits, x stands for a number of times you want the layer to wiggle and y stands for the number of frames in which you want that layer to move.

Adding the expression wiggle(10,20) to the position property of a layer will randomly wiggle it 10 times in every 20 frames interval.

But what if we want to start or stop the layer to wiggle at a specific time. With few lines of code, we can begin and end the influence of the wiggle expression at a specific time.

START STOP WIGGLE EXPRESSION

To begin with, we need to apply the wiggle expression to the position property of the layer.

  1. Select the layer you want to wiggle and hit P on your keyboard to open the position property.
  2. Hold ALT on your keyboard and click on the stopwatch icon.
    wiggle1
  3. Delete transform.position from the text area and type in the wiggle expression.
    wiggle2

Here comes the fun part, the basic wiggle expression will wiggle the layer for the entire duration. Update the expression with below codes to start and stop the wiggle effect at a specific time.

Apply the following expression to wiggle it beginning at time 5 seconds:

timeToStart = 5; 
if (time > timeToStart) 
{ wiggle(10,20); 
} else { 
value; 
}

Apply the following expression to a property to stop wiggling it at time 10 seconds:

timeToStop = 10; 

if (time > timeToStop) { 
value; 
} else { 
wiggle(10,20); 
}

Apply the following expression to a property to start wiggling it at time 5 seconds and stop wiggling it at time 10 seconds:

timeToStart = 5; 

timeToStop = 10; 
if ((time > timeToStart) && (time < timeToStop)) { 
wiggle(10,20); 
} else { 
value; 
}

Make sure you use the expression in the correct format and double check the parentheses.

LEAVE A REPLY

Please enter your comment!
Please enter your name here

21,162FansLike
2,813SubscribersSubscribe
 500+ LIGHTROOM PRESETS 
 WORTH $467 FOR JUST $29  

Discount
Upto 94%

LIMITED TIME OFFER
GET THE BUNDLE FOR JUST $29
close-link
Download 546 Lightroom Presets Worth $467 For Just $29.