|
Post by Ashley Hall on Mar 24, 2005 17:49:43 GMT 10
Draw the shape you want as your cursor and select it. Now right click it and click on "convert to symbol". Name it whatever you like but make sure it's a movieclip. Select the movieckip and press F9 to get the actions for it up (if they're not already) and copy this into them. onClipEvent(enterFrame){ startDrag (this,true); Mouse.hide(); } Alternatively, you could have this: onClipEvent(enterFrame){ this._x = _root._xmouse; this._y = _root._ymouse; Mouse.hide(); }
Now to break the code down onClipEvent(enterFrame) - every frame that this clip is in startDrag - Start Drag . Inside the brackets is - (target,lockcentre,left,top,right,bottom) now to break that down : target - what you want to drag lockcenter - true or false if you want to lock the cursor to the center of the movieclip left top right bottom - the constraints, enter 0,0,300,300 for it to be bound 300 pixels from the top left corner
Mouse.hide(); - hide the mouse this._x = _root._xmouse - the x coords of this movieclip are the same as the mouse's x coords. this._y = _root._ymouse - same as above but y instead of x
FINISHED YAY! ^_^
[/b]
|
|
|
Post by mitchell on May 24, 2005 16:58:07 GMT 10
put more tutorals on cos i can't use flash for shit
|
|
|
Post by Ashley Hall on May 24, 2005 19:57:23 GMT 10
oi is this mitchell luke? if not then o well pleased 2 meet ya mitch. anyways a good place to learn flash is www.flashkit.com/
|
|