|
||||||
|
||||||
Flash Tutorial - Mask Attached to the Mouse
Free
Flash Tutorial
Step Two: Attaching the Circle to the Mouse

ActionScript Explained
onClipEvent (enterFrame) {
Do the following every time the Play Head enters the frame. This would normally be 12 times per second.
startDrag(this, true);
Start to drag this object (the circle symbol). The true centres the object to the middle of the mouse.
}
End of the clip event.
You want to test your movie: Control > Test Movie
Your circle should stick to the centre of the mouse cursor.
You may wish to try and test the movie without the true so that you can see the difference. Change the line of code so that it looks like this: startDrag(this); and test it again.
Cross Ref: You can only attach one object at a time to the mouse this way. If you wish to attach several objects to your mouse you will need to use a different method see the Intermediate tutorial: Creating a Magnifying Glass
|
Why not try out webwasp's new community. Meet new people, find friends in your area: Webwasp Mates & Dates
•
84647 visitors to this page since Jan 04 |
|
|
All material on this site is protected under international copyright © law. DO NOT reproduce any material from this site without written permission. Please ask as permission is often granted.
|