# Add Bounding Box to MovieClip?

**URL:** https://forum.kirupa.com/t/add-bounding-box-to-movieclip/270398
**Category:** flash
**Created:** [September 9, 2008, 3:26pm UTC](https://forum.kirupa.com/t/add-bounding-box-to-movieclip/270398 "2008-09-09T15:26:32Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![svdelle](https://avatars.discourse-cdn.com/v4/letter/s/8797f3/32.png) [@svdelle](https://forum.kirupa.com/u/svdelle)
#### Post date: [September 9, 2008, 3:26pm UTC](https://forum.kirupa.com/t/add-bounding-box-to-movieclip/270398/1 "2008-09-09T15:26:32Z")

</div>

I have a large graphic consisting of letters from Illustrator. I paste these into flash, break them up into smaller groups and convert these groups to MovieClips. Because of the enormous amount of MovieClips that I have to convert by hand (pressing F8 and Enter), I simply use the default naming of symbols that Flash suggests Symbol 1, Symbol 2 … Symbol 3245.

I place all these MovieClips into one parent MovieClip (select them all and press F8). And at runtime I add EventListeners to them all using this:

```auto

for(var i = 0; i < letter_ocean_mc.numChildren; i++)
{
 var mc:DisplayObject = letter_ocean_mc.getChildAt(i);
 mc.alpha = .1;
 mc.addEventListener(MouseEvent.MOUSE_OVER, mOver);
 mc.addEventListener(MouseEvent.MOUSE_OUT, mOut);
}

```

I can now apply the same effect to all these clips at once, which is nice. But …

My problem is, that because each group consist of letters, I can only get Mouse Over Event when I touch the letters them selves, not the holes in the letters and the space between them.

I thought I could easily add a mask or bounding box to get the whole MovieClip to respond to MouseEvents. I hope I thought right, but I just can’t seem to get anything to work. I’ve tried creating both new Sprites, MovieClips, DisplayObjects, Shapes … you name it, and add them to the instance like this:  
mc.addChild(myMask); (where myMask has been any of the above mentioned types - both with and without drawn shapes).

Does anyone have any idea how to achieve a thing like this? And it has do be done dynamically, as I haven’t got the three months or so to do it by hand (not to mention if I had to update the graphic ☹ ).
