Article

Home » Design and Layout » Flash Tutorials » Flash Script - 3D Perspective Moving Effect

About the Author

SitePoint

View all articles by SitePoint...

Flash Script - 3D Perspective Moving Effect

By SitePoint

April 28th, 2003

Reader Rating: 7

Many Flashers asked me how to create a 3d perspective effect, so here it is! Download the sample files here.

1. Create a grid using the line tool:

1100_line1

Convert this to a graphic object.

3. Make a duplicate of the graphic, and mirror it as shown below:

1100_line2

4.Create a line as shown below.

1100_line3

Convert this to a movie clip.

5. Give this movie clip an instance name of line.

6. Go to the timeline of the line movieclip, and create three keyframes as shown below.

1100_tool4

7. In the first keyframe, insert the action:

y = /:initpos
incr = 1;

8. In the second keyframe, insert:

setProperty ("", _y, y);
y = y+incr;
incr = incr + .2;

9. In the third keyframe, insert the action:

gotoAndPlay (2);

10.Go back to the main time line, create two layers above the existing layer, and name them as shown below.

1100_tool5

Make sure that the line movieclip is in the line layer.

11.Select the 8th frame of all the layers, and press f5. This will extend the frame to the 8th.

12. Go to the actions layer and in the first frame, insert the action:

initpos = getProperty("/line",_y);
y = initpos;
incr = 1;
18.In the second frame give action:
duplicateMovieClip ( "/line","line" add incr, incr);
incr = incr + 1;
if((getProperty("/line" add incr,_y)) > 400)
{
removeMovieClip ("/line" add incr);
}

13. In the last frame, inser the action:

gotoAndPlay (2);

If you liked this article, share the love:
Print-Friendly Version Suggest an Article

Sponsored Links

Rate This Article

  • 1
    Poor
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
    Great

Comment on This Article

Have something to say?

Post A Comment

You need to be a member of the SitePoint Forums to comment on this post. Sign Up

Already a member? Post using your SitePoint Forums account: