# cs5.5 AS 3.0: move movieclip to fixed point on rollover

**URL:** <https://forum.kirupa.com/t/cs5-5-as-3-0-move-movieclip-to-fixed-point-on-rollover/331273>\
**Category:** flash\
**Created:** [June 26, 2013, 3:56pm UTC](https://forum.kirupa.com/t/cs5-5-as-3-0-move-movieclip-to-fixed-point-on-rollover/331273 "2013-06-26T15:56:46Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![JBlij](https://avatars.discourse-cdn.com/v4/letter/j/82dd89/32.png) [@JBlij](https://forum.kirupa.com/u/JBlij)\
**Post date:** [June 26, 2013, 3:56pm UTC](https://forum.kirupa.com/t/cs5-5-as-3-0-move-movieclip-to-fixed-point-on-rollover/331273/1 "2013-06-26T15:56:46Z")

</div>

I currently have a maze made where my circle (instancename = Muis2) moves around when my mouse moves around. When it mouses over the walls of my maze (Instancename = Maze) I want the circle to move back to its beginning position (x = 908, y = 137). I can find all kinds of tutorials and Code Snippets, but none help me with my specific problem. This is probably because it shouldn’t be that difficult. I am just not that good at all this. I hope you can help me. The code I have until now is this.

stage.addChild(Muis2);  
Muis2.mouseEnabled = false;  
Muis2.addEventListener(Event.ENTER\_FRAME, fl\_CustomMouseCursor\_2);

function fl\_CustomMouseCursor\_2(event:Event)  
{  
Muis2.x = stage.mouseX;  
Muis2.y = stage.mouseY;  
}  
Mouse.hide();

Maze.addEventListener(MouseEvent.MOUSE\_OVER, fl\_MouseOverHandler\_3);

function fl\_MouseOverHandler\_3(event:MouseEvent):void  
{

```
trace("Moused over");

```

}

And it works if I add a trace code in the mouseover event. The only thing is that I need to add a custom code in the mouseover command so that when my circle (Muis2) mouses over my Wall it gets put back in the position where it came from. Hence, it needs to move to the position where it was (previous given x,y coordinates). I hope someone here can help me out! Thanks!
