# Including or Excluding the Current MovieClip on Tween

**URL:** https://forum.kirupa.com/t/including-or-excluding-the-current-movieclip-on-tween/332586
**Category:** flash
**Created:** [August 5, 2014, 1:02pm UTC](https://forum.kirupa.com/t/including-or-excluding-the-current-movieclip-on-tween/332586 "2014-08-05T13:02:17Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![atoyansk](https://avatars.discourse-cdn.com/v4/letter/a/c37758/32.png) [@atoyansk](https://forum.kirupa.com/u/atoyansk)
#### Post date: [August 5, 2014, 1:02pm UTC](https://forum.kirupa.com/t/including-or-excluding-the-current-movieclip-on-tween/332586/1 "2014-08-05T13:02:17Z")

</div>

Hi all,

I have 3 MCs on my stage, and I am applying motion tween for all of them dynamically, in this way:

```auto

var nav_array:Array = new Array("Home", "About", "Info");

for (var i:int=0; i<nav_array.length; i++) {
    var objeto = this["my_mc"+i];
    objeto.navText.text = nav_array*;
    var efeito = "x";
    var anima = Strong.easeInOut;
    var pos_ini = objeto.x;
    var pos_fin = objeto.x+200;
    objeto.myTween = new Tween(objeto, efeito, anima, pos_ini,pos_fin, 1, true);
    objeto.myTween.stop();
    objeto.addEventListener(MouseEvent.CLICK, onClick);
} 

function onClick(e:MouseEvent):void {
    var objeto2:MovieClip = e.currentTarget as MovieClip
    objeto2.myTween.start();
    trace(objeto2.name);
}

```

However, as you see, I’m considering only the current movieclip.  
Now, I need to alter this code to the follow situations:  
[LIST=1]  
[_]When any MC is clicked, Motion Tween would be applied to all, **including** the current object  
[_]When any MC is clicked, Motion Tween would be applied to all, **except** the current object  
[/LIST]  
What are changes needed in my code to meet the above situations?

Thanks for any help.
