# Collision and Stop

**URL:** <https://forum.kirupa.com/t/collision-and-stop/221781>\
**Category:** flash\
**Created:** [April 7, 2007, 5:26pm UTC](https://forum.kirupa.com/t/collision-and-stop/221781 "2007-04-07T17:26:04Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Gabi](https://avatars.discourse-cdn.com/v4/letter/g/f07891/32.png) [@Gabi](https://forum.kirupa.com/u/Gabi)\
**Post date:** [April 7, 2007, 5:26pm UTC](https://forum.kirupa.com/t/collision-and-stop/221781/1 "2007-04-07T17:26:04Z")

</div>

Still try to solve my problem , but i don’t know how . I have a mc whice go to mouse when i press leftbutton.

```auto
onClipEvent(load){
    _x=0;
    _y=0;
    slow=10;
}
onClipEvent(mouseDown){
    endX=_root._xmouse;
    endY=_root._ymouse;
}
onClipEvent(enterFrame){
    _x +=(endX- _x)/slow;
    _y +=(endY- _y)/slow;
}

```

and for collision i know how to do  
\_root.mc.hitTest(\_root.mc2)  
This code maybe i 'll put in enterFrame with a condition  
My question is …how to stop my increment mc when this touch mc1
