Issues ... lots and lots of issues

Hey everyone,
I’ve decided to jump back into the Flash pool and started playing around with various tutorials to get back into the Flash mindset.

I was plating around with the Experiments in Perspective tutorial located on the site one thing led to another and I came up with a faily neat effect.

The main problem is that the original version I came up with required manually duplkicating the movie clip over and over and over. I got the effect I wanted but this was hardly efficient.

So I started tinkering with the _root statement that duplicated the movie clip automatically:

counter1=19;
for (m=1;m<counter1;m++)
{
duplicateMovieClip(_root.ball1,“ball1”+m,m);
}

This does what I want but if I want to make another instance of the code below that code it seems to execute the top code once and then continues on with the bottom code the proper amount of times.:

counter2=19;
for (k=1;k<counter1;k++){
duplicateMovieClip(_root.ball2,“ball2”+m,m);
}

My plan was to apply this effect initially to four movie clips but duplication only happens to one of them.

I am not sure how the for statement works so maybe it runs through the first three duplication sections once then completes the fourth one in its entirety but I am not sure how to set it up so that all of them are duplicated the correct number of times.

Also, when I change the counter codes around I do get the duplication of more than on movie clip but I am not quite sure the exact reason why.

Thanks.

Brian