# Custom cursor \*and\* startDrag for dragging objects?

**URL:** <https://forum.kirupa.com/t/custom-cursor-and-startdrag-for-dragging-objects/280786>\
**Category:** Uncategorized\
**Created:** [January 31, 2009, 9:33pm UTC](https://forum.kirupa.com/t/custom-cursor-and-startdrag-for-dragging-objects/280786 "2009-01-31T21:33:22Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![chronopsis](https://avatars.discourse-cdn.com/v4/letter/c/3be4f8/32.png) [@chronopsis](https://forum.kirupa.com/u/chronopsis)\
**Post date:** [January 31, 2009, 9:33pm UTC](https://forum.kirupa.com/t/custom-cursor-and-startdrag-for-dragging-objects/280786/1 "2009-01-31T21:33:22Z")

</div>

as i attempt to migrate over to 3.0, i’m stumped by what’s probably a simple goof. I’ve made a working custom cursor, but a separate mc which was a draggable object with the default cursor now ignores the custom cursor.

any help greatly appreciated!!

my code:

[FONT=Courier New]stage.addEventListener(MouseEvent.MOUSE\_MOVE, newCursor);  
Mouse.hide();  
rectangle2\_mc.addEventListener(MouseEvent.MOUSE\_DOWN, dragger);  
rectangle2\_mc.addEventListener(MouseEvent.MOUSE\_UP, dropper);

//cursor replacement function  
function newCursor(event:MouseEvent):void {  
cursor\_mc.x = mouseX  
cursor\_mc.y = mouseY;  
event.updateAfterEvent();  
}

//dragging function  
function dragger(event:MouseEvent):void {  
event.target.startDrag();  
}

//dropping function  
function dropper(event:MouseEvent):void {  
event.target.stopDrag();  
}

[/FONT]
