Mouse Induction Flower Rotation effect

Source: Internet
Author: User
Induction | mouse

  Demo effect : ( You can see the effect with the mouse )

/uploadpic/2007-7/20077812218828.swf

Click here to download the source file

First, we turn the background to black and the stage is 300x300


Draw a flower, select it, and press the F8 key to convert to a movie clip:


Then make a transition effect like this: the first frame code:

Stop ();


Drag it into the scene, determine it in the center of the scene with the alignment panel, and select it to enter as:

Onclipevent (enterframe) {
_ROOT.SP = Math.floor ((_ymouse+50)/6)//calculation speed
if (_ymouse>150) {
_rotation-= _ROOT.SP;
NextFrame ();
}//rotation
if (_ymouse<150) {
_rotation + = _ROOT.SP;
Prevscene ();
}//rotation
Copy a few, _alpha are 50,20 (or you can change it yourself)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.