# Mutliple movie clips

**URL:** <https://forum.kirupa.com/t/mutliple-movie-clips/283088>\
**Category:** Uncategorized\
**Created:** [March 2, 2009, 4:06pm UTC](https://forum.kirupa.com/t/mutliple-movie-clips/283088 "2009-03-02T16:06:08Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![michdd](https://avatars.discourse-cdn.com/v4/letter/m/b4bc9f/32.png) [@michdd](https://forum.kirupa.com/u/michdd)\
**Post date:** [March 2, 2009, 4:06pm UTC](https://forum.kirupa.com/t/mutliple-movie-clips/283088/1 "2009-03-02T16:06:08Z")

</div>

I have some code like this:

```auto

for (var yt:int = 0; yt < mapH; yt++) {
	for (var xt:int = 0; xt < mapW; xt++) {
                drawTile(s, xt, yt);
        }
}

```

Which will look through a 2 dimensional array, then I need to create a new MovieClip for each value in that array, using something like this:

```auto

var mc:tile_mc = new tile_mc();

```

Except it needs to make more than one of these movieclips (all with different names), and I need to be able to pass to movieclip name through the drawTile() function, or have some way of knowing what it is for the current loop…

Is there some way that I can like make the name of the movie clip “tile\_” + yt + “\_” + xt ? Since yt and xt change every loop and I’m already passing those values through drawTile
