# Change mc position when mouse stops moving

**URL:** <https://forum.kirupa.com/t/change-mc-position-when-mouse-stops-moving/290994>\
**Category:** flash\
**Created:** [June 23, 2009, 1:35pm UTC](https://forum.kirupa.com/t/change-mc-position-when-mouse-stops-moving/290994 "2009-06-23T13:35:48Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![rbp](https://avatars.discourse-cdn.com/v4/letter/r/cc9497/32.png) [@rbp](https://forum.kirupa.com/u/rbp)\
**Post date:** [June 23, 2009, 1:35pm UTC](https://forum.kirupa.com/t/change-mc-position-when-mouse-stops-moving/290994/1 "2009-06-23T13:35:48Z")

</div>

Hi guys!

I’ve got this:  
[http://megaswf.com/view/acfd77138f2afbd136942c83759f1c46.html](http://megaswf.com/view/acfd77138f2afbd136942c83759f1c46.html)

and need to add a function which changes position of those three mc’s(myMC, myKulicka,myStin) to the center whenever the MouseMove stops. Thx for any advice

Used AS:

\_root.onEnterFrame=function(){  
if (startMoving==true){  
myMC.\_rotation=\_xmouse;  
myMC.\_x=\_xmouse;  
myMC.\_y=360;  
myKulicka.\_x=\_xmouse;  
myKulicka.\_y=360;  
myStin.\_x=\_xmouse;  
myStin.\_y=360;  
}  
}  
myMC.onRollOver=function(){  
startMoving=true;  
}  
myKulicka.onRollOver=function(){  
startMoving=true;  
}  
myStin.onRollOver=function(){  
startMoving=true;  
}
