# Movie clip difficulity

**URL:** <https://forum.kirupa.com/t/movie-clip-difficulity/218458>\
**Category:** Uncategorized\
**Created:** [March 7, 2007, 11:14pm UTC](https://forum.kirupa.com/t/movie-clip-difficulity/218458 "2007-03-07T23:14:57Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![puthem1st](https://avatars.discourse-cdn.com/v4/letter/p/ecb155/32.png) [@puthem1st](https://forum.kirupa.com/u/puthem1st)\
**Post date:** [March 7, 2007, 11:14pm UTC](https://forum.kirupa.com/t/movie-clip-difficulity/218458/1 "2007-03-07T23:14:57Z")

</div>

Hi and thanks for viewing this thread. I have 3 movie clips that I want to place on the stage through actionscript. The movie clips are set up in an array so they can be selected however my problem is that it seems as if they are overlapping.

```auto

var shapes:Array = new Array("square", "circle", "rectangle");
var letters:Array =new Array("alpha", "beta", "gama");
var names:Array =new Array("Barney", "Sponge Bobb", "Dora");
var myAlpha:Array=[];
var one:Number;
var two:Number;
var three:Number;
function selectalpha(){
  var minNum:Number = 0;
  //Gets the lenght of an array and returns a value
  var maxNum:Number = shapes.length;
  one = Math.ceil(Math.random()*(maxNum-minNum+1))+(minNum-1);
  //pushes the value into an array
  myAlpha.push(one);
  
   minNum = 0;
   maxNum = letters.length;
  two = Math.ceil(Math.random()*(maxNum-minNum+1))+(minNum-1);
  myAlpha.push(two);
  
   minNum = 0;
   maxNum = names.length;
  three = Math.ceil(Math.random()*(maxNum-minNum+1))+(minNum-1);
  myAlpha.push(three);
  
  pulltogether(myAlpha);
 }
trace(three);
//calls the function that will place the shapes on the stage
function pulltogether(test:Array) {
 _root.createEmptyMovieClip("Placement", 2);
 Placement.attachMovie(shapes[0],Placement.getNextHighestDepth(), {_x:0, _y:0});
 Placement.attachMovie(letters[0],Placement.getNextHighestDepth+1(), {_x:0, _y:0});
 Placement.attachMovie(names[0],Placement.getNextHighestDepth+2(), {_x:0, _y:0});
  Placement._x = 190;
  Placement._y = 50;
}

```

I traced my depths and I got  
shapes depth=1  
letters depth=1  
names depth =1

For some reason if all my depths are 1 only 1 of the movie clips will display

if depth are different  
shapes depth=0  
letters depth=2  
names depth =3

The display correctly. It seems to alternate and I don’t know how to control it.
