How to drag an image to move it smoothly on screen, with ActionScript?
I was thinking this is a simple task, but I'm wrong. I used a sprite to display an image, and when user drag it(MOUSE_DOWN and MOUSE_MOVE), I got the position in MOUSE_MOVE and calculated the offsets: var current: Point = new Point(event.localX, event.localY); sprite.x = current.x - start.x; sprite.y = current.y - start.y; It works but not smooth. Is there a better solution? UPDATE After a day of debugging, I finally found the reason. Bigger fps can make it smoother, but it's not the key of this question. The key is I should use stage to listen MOUSE_MOVE , not the image itself. And when