1. Home
  2. Computing & Technology
  3. Animation

Animated Flash-Only Thumbnail Gallery I

By , About.com Guide

10 of 10

That animates it up to the point where it stops at full enlargement. Now we need to add to the script so that when the mouse rolls out, the animation skips past that stop point and plays down to shrinking to original size again by going to the frame after the second stop:
on (rollOver) {
this.gotoAndPlay(2);
this.swapDepths(1);
}
on (rollOut) {
this.gotoAndPlay(8);
}

You may also want to use swapDepths, as I did, to pull the thumbnail one layer above all the others so that the expanded image overlaps the other thumbnails rather than vanishing behind it.

All you need to do now is copy-paste the exact same code onto each thumbnail; since it uses “this” to point to the movie clip that the script is attached to rather than a specific instance name, it doesn’t require any changes so if you want, you can use an #include instead to reference the duplicated code.

Take a look at the working version here.

Explore Animation
About.com Special Features

Holiday Central

What to eat, where to go, fun things to do and how to save money on the perfect gifts. More >

Family Tech Center

Stay connected and entertained with reviews on tips on the latest HDTVs, cellphones and more. More >

  1. Home
  2. Computing & Technology
  3. Animation
  4. Flash Animation Tutorials
  5. Animated Flash-Only Thumbnail Gallery I

©2009 About.com, a part of The New York Times Company.

All rights reserved.