# Duplicating Multiple Movie Clips

**URL:** https://forum.kirupa.com/t/duplicating-multiple-movie-clips/235235
**Category:** flash
**Created:** [August 9, 2007, 2:40pm UTC](https://forum.kirupa.com/t/duplicating-multiple-movie-clips/235235 "2007-08-09T14:40:44Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![billy\_nugz](https://avatars.discourse-cdn.com/v4/letter/b/b9bd4f/32.png) [@billy\_nugz](https://forum.kirupa.com/u/billy_nugz)
#### Post date: [August 9, 2007, 2:40pm UTC](https://forum.kirupa.com/t/duplicating-multiple-movie-clips/235235/1 "2007-08-09T14:40:44Z")

</div>

Hello im using flash 8  
Ok so I went through a tute on the site which explained this code

```auto
dupMovie = function () { 
for (i=0; i<100; i++) { 
circle.duplicateMovieClip("circle"+i, i, {_x:Math.random()*600, _y:Math.random()*600, _alpha:Math.random()*50}); 
with (eval("circle"+i)) { 
_xscale = _yscale=Math.random()*300; 
} 
} 
}; 
dupMovie();

```

I know movie clips cant live at the same depth, and the tute breifly touches on useing getNextHighestDepth(). However im not familar with that parameter.

This is what im doing wrong

```auto
dupMovie = function () { 
for (i=0; i<100; i++) { 
circle.duplicateMovieClip("circle"+i, i, {_x:Math.random()*600, _y:Math.random()*600, _alpha:Math.random()*50}); 
with (eval("circle"+i)) { 
_xscale = _yscale=Math.random()*300; 
} 
} 
}; 
dupMovie();
//
dupMovie2 = function () { 
for (i2=0; i2<100; i2++) { 
circle2.duplicateMovieClip("circle"+i2, i2, {_x:Math.random()*600, _y:Math.random()*600, _alpha:Math.random()*50}); 
with (eval("circle2"+i2)) { 
_xscale = _yscale=Math.random()*300; 
} 
} 
}; 
dupMovie2();

```

Any responce is welcome
