Interesting! Use Flash to make interactive villain

Source: Internet
Author: User
We first take a look at the results of the case, the scene has six small balls, respectively, representing the head, waist, hands, feet, if you drag the mouse with any part of the body, the rest of the body will make corresponding movements, the whole body of the changes in the position between the parts is very coordinated.

The implementation is actually very simple, let's take a step-by-step to make this instance effect.

1, open Flash, create a new scene, press Ctrl + F8 to create a new clip, name "Symbol 5", type "button", use the Ellipse tool to draw a circle in this clip scene, and fill a gradient color with the Fill tool, as shown in the figure.

2. Press Ctrl + F8 to create a new Clip named "Symbol 1", type "Movie Clip", drag "symbol 5" made in the previous step into this Clip scene, and in "Symbol 5" The Clip Action panel adds the following statement:

On (Press) {
This.startdrag (); When the mouse clicks, drag clip
}
On (release, releaseoutside) {//When the mouse is released, stop dragging clip
This.stopdrag ();
}


3, press "Ctrl + F8" to create a new Clip, named "Symbol 4", type "Movie Clip", with the line tool in this Clip scene to draw a short line.

4, press "Ctrl + F8" to create a new Clip, named "Symbol 1 copy", type "Movie Clip", drag "symbol 5" in the first step to this Clip scene, and in "Symbol 5" The Clip Action panel adds the following statement:

On (Press) {
This.startdrag ();
drag = 1;
}
On (release, releaseoutside) {
This.stopdrag ();
drag = 0;
}

5, in "Symbol 1 copy" clip, right-click the layer above the timeline, choose Insert a new layer, drag "symbol 4" from step three into the newly inserted layer scene, select "Symbol 4" in the scene, and set the instance on the property panel to be named " Link ".

6. In the Symbol 1 copy clip, right-click the layer above the timeline, and then select Insert a new layer, insert the following statement above the action panel on the first frame of the layer:







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.