Search Our Web Design Blog...

Tuesday, November 15, 2011

an easier way...

if you do not need your cursor to be very precise:

name your instance name for your new cursor movieclip "cursor"
then add this code to frame 1 of your main timeline:

Mouse.hide();
stage.addEventListener(MouseEvent.MOUSE_MOVE,follow);
function follow(evt:MouseEvent){
 cursor.x = mouseX;
 cursor.y = mouseY;
}
 
 
 
Now all you need to do is double click on your movie clip and
move the object to align with the crosshair (this is the registration
point for your cursor).
 
 

No comments:

Post a Comment