Clamp MovieClip to only be draggable inside stage?

Posted by Zolomon on Stack Overflow See other posts from Stack Overflow or by Zolomon
Published on 2010-03-19T21:42:47Z Indexed on 2010/03/19 22:11 UTC
Read the original article Hit count: 222

Filed under:
|

I have a MovieClip that I want the user to be able to drag inside the stage, but I don't want it to be able to move outside the stage.

Currently I'm using this._parent.startDrag(); to allow the MC to be dragged, but I don't know how to stop it from being dragged outside the frame.

© Stack Overflow or respective owner

Related posts about actionscript-2

Related posts about flash