Publishers of technology books, eBooks, and videos for creative people

Home > Articles > Design > Adobe Creative Suite

Animation with Scripting for Adobe Flash Professional CS5 Studio Techniques: Character Animation

Optimization and efficiency are key elements for a web project that needs to load quickly and play smoothly. Chris Georgenes and Just Putney explain how to animate characters in Adobe Flash Professional CS5.
From the book

Building a Character in Flash

Before rendering your character in Flash, consider how your character will need to move. Will your character be walking, running, flying, or falling at any point throughout the project? Optimization and efficiency are key elements for a web project that needs to load quickly and play smoothly. The more times an object can be reused, the more efficient the file will be.

After you import your sketch into Flash, you should consider how the character's features could best work as individual objects. This process depends ultimately on your style of animation and the style of your character. Efficient use of symbols will facilitate the production of cutout-style animation in Flash.

Working with Symbols

Symbols are the building blocks of Flash. You can convert anything you draw or import into a symbol, and there's a good reason to do so: When an object is converted into a symbol, it automatically becomes an item in the Flash document's Library. Every Flash document has its own Library from which you can drag a symbol onto the Stage. When you do so, the object on the Stage is referred to as an instance. No matter how many instances of a symbol reside on the Stage, Flash only needs to load the source symbol once. This is how Flash delivers smoothly streaming animations while maintaining small file sizes. It's extremely efficient to reuse symbols as many times as possible. You can also apply effects such as Scale, Tint, Alpha, and Brightness to instances and apply Motion Tweens in combination with one or more effects without increasing file size.

When you convert artwork to a symbol, you have a choice of three possible symbol behaviors:

  • Movie Clip. Movie Clips are dynamic, which means they can be targeted with ActionScript, the Flash programming language. They can have any number of layers and frames, but their Timelines are independent of all other Timelines. Movie Clips can have Blend Modes and Filters applied to them to achieve sophisticated effects. You will utilize Movie Clips in Chapters 3 and 5 to create custom effects and behaviors. Movie Clips can also be created dynamically at runtime and can also act as a container for other objects, such as external images.
  • Button. Buttons have four states: Over, Up, Down, and Hit. These are represented as keyframes in a button symbol's Timeline. You can place graphics in any of these states and then apply ActionScript to the instance of a button to add interactivity to your Flash movie.
  • Graphic. Graphic symbols are similar to Movie Clips except that they are not dynamic and cannot be targeted with ActionScript. Like Movie Clips, Graphic symbols can have any number of frames and layers. Graphics are useful, because their Timelines can be manipulated via the Properties panel. The most important feature of Graphic symbols is that they will always be in sync with parent (Graphic) Timelines and the main Timeline. This feature becomes crucial when you are creating frame-based animations, which is why most animators use Graphic symbols for fixed-frame output formats (such as video). Unlike animation within Movie Clip Timelines, animation nested inside Graphic symbols can be seen when the playhead is moved back and forth along the Timeline within the Flash authoring environment. The only drawback to Graphic symbols is that they do not support Blend Modes or Filters.

In this chapter, you will focus primarily on building a character using Graphic symbols. You will apply a technique known as nesting to easily manipulate the character on the Timeline.

Nesting

The process of nesting involves placing a symbol instance inside another symbol's Timeline. This allows you to manipulate a symbol and all of its nested objects, or children, as a single object.

Flash animators and developers of all stripes lean heavily on the concept of nesting; thus, nesting will play a large role in the techniques covered in this chapter.

Here's a simple example of a character designed for cutout animation ( Figure 2.4).

Figure 2.4

Figure 2.4 This diagram shows a character with nested parts designed for cutout animation.

In Figure 2.4, image A shows the monster character as he will appear when the movie is rendered. Image B illustrates how the monster is broken into component parts. Image C shows how the component parts can be animated individually. Because all the parts are stored within a single symbol, the monster can be animated as a whole as well. The next section demonstrates the process of creating a character with nested parts.

Building the Driver Character

The driver character pictured in Figure 2.5 plays a small role in the Sausage Kong game introduced in Chapter 1. The driver appears after time has elapsed in the game, and he is only seen from the side while he is driving his truck and then when he is running across the Stage. Due to the character's limited movement, we only need to design a single view of the character.

Figure 2.5

Figure 2.5 Concept sketches of the driver character.

Working with the imported sketch

You'll use the sketch of the driver as a guide for your Flash artwork.

  1. Choose File > New, (under the General heading) select ActionScript 3.0 at the left, and click OK to create a new document (Figure 2.6 on the next page).
    Figure 2.6

    Figure 2.6 The New Document dialog box allows you to create a new blank document.

  2. Save the file as driver.fla.
  3. Choose File > Import > Import to Stage, locate the Chapter 2 /assets/driver_sketch.tiff file on the accompanying CD, and click Open.
  4. With the imported sketch selected, press the F8 key to convert the sketch to a Graphic symbol. Name the symbol sketch, and click OK.
  5. In the Position and Size area of the Properties panel, ensure that the chain link icon is unbroken so that width and height will be scaled proportionally, and change the W value to 550 (Figure 2.7).
    Figure 2.7

    Figure 2.7 Ensure that the height and width values are locked as you scale the sketch instance.

  6. Center the sketch on the Stage (Figure 2.8).
    Figure 2.8

    Figure 2.8 The sketch is now centered on Stage.

  7. In the Color Effect area of the Properties panel, select Alpha from the Style menu and set the Alpha value to 30% (Figure 2.9).
    Figure 2.9

    Figure 2.9 The Alpha value settings will render the sketch partially transparent.

  8. Rename the current layer sketch, lock the layer, and covert it to a guide by Ctrl-clicking/right-clicking and choosing Guide.
  9. Create a new layer named head above the sketch layer.
  10. Switch to the Brush tool and ensure that object drawing mode is turned off at the bottom of the toolbar. Using a black fill color, trace the outline of just the head shape. Make sure you overlap your drawing where the head meets the neckline of the body to avoid a gap appearing between them when you start animating later (Figure 2.10).
    Figure 2.10

    Figure 2.10 The top of the head is outlined to match the rough sketch underneath.

  11. Use the Selection tool and Properties panel to soften the black outline to a dark brownish tone (#BE984C), and use the Brush tool to close the neckline gap at the bottom with a line drawn using a lighter yellowish tone (#FFCC66) (Figure 2.11).
    Figure 2.11

    Figure 2.11 The neck and head graphic outline drawn using Flash's Brush tool.

  12. Use the Paint Bucket tool to fill in the head with the lighter tone (Figure 2.12).
    Figure 2.12

    Figure 2.12 The completed head artwork.

  13. Select the entire head artwork and press F8 to bring up the Convert to Symbol dialog box. Name your Graphic symbol driver_head and click OK (Figure 2.13).
    Figure 2.13

    Figure 2.13 Convert the head to a Graphic symbol.

  14. Save your document.

The next step is to add the eye graphics.

Drawing the driver's eye

You'll create three different objects: the shadow of the eye socket, the white of the eye, and the pupil.

  1. In your driver.fla file, lock and hide your head layer, and create a new layer named eye.
  2. Switch to the Oval tool, select the darker fill color (#BE984C) with no stroke, and draw a circle (Figure 2.14).
    Figure 2.14

    Figure 2.14 The circle that will become the completed eye.

  3. Because the top half of the driver's eye is designed in a way that it can't be seen, you'll cut the circle in half horizontally. Using the Selection tool, drag a marquee over the top half of the circle (Figure 2.15).

    Figure 2.15

    Figure 2.15 Use the Selection tool to select the top half of the circle.

    When you release the Selection tool, the upper half of the circle will be selected (Figure 2.16).

    Figure 2.16

    Figure 2.16 The partially selected circle will appear with small dots to indicate the selected area.

  4. Press the Delete key to remove the top half of the circle (Figure 2.17).
    Figure 2.17

    Figure 2.17 The resulting semicircle.

  5. Switch to the Free Transform tool, and rotate and scale the semicircle to fit the eye shape on the sketch (Figure 2.18).
    Figure 2.18

    Figure 2.18 Use the Free Transform tool to rotate the semicircle.

  6. For the eyeball, copy the semicircle (Command+C/Ctrl+C) and paste a copy in place (Command+Shift+V/Ctrl+Shift+V). Scale down the new shape and replace the fill color with white (Figure 2.19).
    Figure 2.19

    Figure 2.19 The eyeball shape is now in place.

  7. Use the Brush tool (or the Oval tool) with a black fill to add a pupil (Figure 2.20).
    Figure 2.20

    Figure 2.20 A pupil is added to the eye.

  8. Turn the head layer visibility on. Select the eye layer and group the eye parts together (Command+G/Ctrl+G). Use the Free Transform tool to position and rotate the eye to fit on the head (Figure 2.21).
    Figure 2.21

    Figure 2.21 The completed eye is now in place.

Save your file, and let's get a cap on this fella!

Drawing the driver's hat

The hat is drawn in a manner similar to the eye. You'll start with basic shapes and then manipulate them into something more complex.

  1. Lock and hide all of your existing layers and create a new layer named hat.
  2. Use the Oval tool to draw a circle with a light blue fill (#58A3ED) and no stroke (Figure 2.22).
    Figure 2.22

    Figure 2.22 The initial circle created with the Oval tool for the character's hat.

  3. Use the Transform tool to squash the circle to a very thin oval (Figure 2.23).
    Figure 2.23

    Figure 2.23 The squashed shape will form the brim of the hat.

  4. Using the Selection tool, draw a marquee over the right half of the thin oval and press the Delete key (Figure 2.24).
    Figure 2.24

    Figure 2.24 The hat now has a flat right edge.

  5. Create a larger light blue circle, but this time select and delete the bottom half of the circle (Figure 2.25).
    Figure 2.25

    Figure 2.25 The second shape with a flat bottom edge.

  6. Use the Free Transform tool to stretch the current shape vertically (Figure 2.26).
    Figure 2.26

    Figure 2.26 The semicircle stretched vertically using the Free Transform tool.

  7. Use the Selection tool to align the bottom edges and merge the two light blue shapes together. The end result should look like a hat with a brim (Figure 2.27).
    Figure 2.27

    Figure 2.27 The driver's hat with a brim.

  8. To add a two-tone color design to the hat, use the Rectangle tool to create a dark blue (#0066CC) rectangle inside the hat (Figure 2.28).
    Figure 2.28

    Figure 2.28 The first step in applying a two-tone color to the hat.

  9. Switch to the Selection tool and make sure the Snap feature is on in the toolbar (Figure 2.29).
    Figure 2.29

    Figure 2.29 The Snap feature in the toolbar must be turned on.

  10. Using the Selection tool, drag each corner so that the bottom edges (Figure 2.30) and the top edges (Figure 2.31) of the shape snap to the edges of the hat.
    Figure 2.30

    Figure 2.30 Use the Selection tool to snap the color patch to the bottom and left edges of the hat.

    Figure 2.31

    Figure 2.31 Use the Selection tool to snap the top of the shape to the edge of the hat.

  11. Use the Paint Bucket tool to fill in the left edge (Figure 2.32).
    Figure 2.32

    Figure 2.32 You can use the Paint Bucket tool to fill in the final piece of the dark blue shape.

  12. Use the Selection tool to curve the right edge of the dark blue shape as if the hat were three-dimensional (Figure 2.33).
    Figure 2.33

    Figure 2.33 Use the Selection tool to curve the darker shape toward the edge of the hat.

  13. Repeat the last several steps (8–12) to create a second dark blue area at the right side of the hat (Figure 2.34).
    Figure 2.34

    Figure 2.34 A second dark blue area is added to the hat.

  14. To be consistent with the rest of the character's design style, use the Ink Bottle tool to add an extra dark blue (#004D9B) stroke to outline the entire hat (Figure 2.35).
    Figure 2.35

    Figure 2.35 The completed hat artwork.

  15. Select the entire hat, group it together (Command+G/Ctrl+G), unhide the sketch layer, and use the Free Transform tool to position and scale the hat so that it fits on the driver's head (Figure 2.36).
    Figure 2.36

    Figure 2.36 Use the Free Transform tool to make the hat appear as though it fits on the driver's head.

Looking good so far! It's time to add some facial hair.

Peachpit Promotional Mailings & Special Offers

I would like to receive exclusive offers and hear about products from Peachpit and its family of brands. I can unsubscribe at any time.

Overview


Pearson Education, Inc., 221 River Street, Hoboken, New Jersey 07030, (Pearson) presents this site to provide information about Peachpit products and services that can be purchased through this site.

This privacy notice provides an overview of our commitment to privacy and describes how we collect, protect, use and share personal information collected through this site. Please note that other Pearson websites and online products and services have their own separate privacy policies.

Collection and Use of Information


To conduct business and deliver products and services, Pearson collects and uses personal information in several ways in connection with this site, including:

Questions and Inquiries

For inquiries and questions, we collect the inquiry or question, together with name, contact details (email address, phone number and mailing address) and any other additional information voluntarily submitted to us through a Contact Us form or an email. We use this information to address the inquiry and respond to the question.

Online Store

For orders and purchases placed through our online store on this site, we collect order details, name, institution name and address (if applicable), email address, phone number, shipping and billing addresses, credit/debit card information, shipping options and any instructions. We use this information to complete transactions, fulfill orders, communicate with individuals placing orders or visiting the online store, and for related purposes.

Surveys

Pearson may offer opportunities to provide feedback or participate in surveys, including surveys evaluating Pearson products, services or sites. Participation is voluntary. Pearson collects information requested in the survey questions and uses the information to evaluate, support, maintain and improve products, services or sites; develop new products and services; conduct educational research; and for other purposes specified in the survey.

Contests and Drawings

Occasionally, we may sponsor a contest or drawing. Participation is optional. Pearson collects name, contact information and other information specified on the entry form for the contest or drawing to conduct the contest or drawing. Pearson may collect additional personal information from the winners of a contest or drawing in order to award the prize and for tax reporting purposes, as required by law.

Newsletters

If you have elected to receive email newsletters or promotional mailings and special offers but want to unsubscribe, simply email ask@peachpit.com.

Service Announcements

On rare occasions it is necessary to send out a strictly service related announcement. For instance, if our service is temporarily suspended for maintenance we might send users an email. Generally, users may not opt-out of these communications, though they can deactivate their account information. However, these communications are not promotional in nature.

Customer Service

We communicate with users on a regular basis to provide requested services and in regard to issues relating to their account we reply via email or phone in accordance with the users' wishes when a user submits their information through our Contact Us form.

Other Collection and Use of Information


Application and System Logs

Pearson automatically collects log data to help ensure the delivery, availability and security of this site. Log data may include technical information about how a user or visitor connected to this site, such as browser type, type of computer/device, operating system, internet service provider and IP address. We use this information for support purposes and to monitor the health of the site, identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents and appropriately scale computing resources.

Web Analytics

Pearson may use third party web trend analytical services, including Google Analytics, to collect visitor information, such as IP addresses, browser types, referring pages, pages visited and time spent on a particular site. While these analytical services collect and report information on an anonymous basis, they may use cookies to gather web trend information. The information gathered may enable Pearson (but not the third party web trend services) to link information with application and system log data. Pearson uses this information for system administration and to identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents, appropriately scale computing resources and otherwise support and deliver this site and its services.

Cookies and Related Technologies

This site uses cookies and similar technologies to personalize content, measure traffic patterns, control security, track use and access of information on this site, and provide interest-based messages and advertising. Users can manage and block the use of cookies through their browser. Disabling or blocking certain cookies may limit the functionality of this site.

Do Not Track

This site currently does not respond to Do Not Track signals.

Security


Pearson uses appropriate physical, administrative and technical security measures to protect personal information from unauthorized access, use and disclosure.

Children


This site is not directed to children under the age of 13.

Marketing


Pearson may send or direct marketing communications to users, provided that

  • Pearson will not use personal information collected or processed as a K-12 school service provider for the purpose of directed or targeted advertising.
  • Such marketing is consistent with applicable law and Pearson's legal obligations.
  • Pearson will not knowingly direct or send marketing communications to an individual who has expressed a preference not to receive marketing.
  • Where required by applicable law, express or implied consent to marketing exists and has not been withdrawn.

Pearson may provide personal information to a third party service provider on a restricted basis to provide marketing solely on behalf of Pearson or an affiliate or customer for whom Pearson is a service provider. Marketing preferences may be changed at any time.

Correcting/Updating Personal Information


If a user's personally identifiable information changes (such as your postal address or email address), we provide a way to correct or update that user's personal data provided to us. This can be done on the Account page. If a user no longer desires our service and desires to delete his or her account, please contact us at customer-service@informit.com and we will process the deletion of a user's account.

Choice/Opt-out


Users can always make an informed choice as to whether they should proceed with certain services offered by Adobe Press. If you choose to remove yourself from our mailing list(s) simply visit the following page and uncheck any communication you no longer want to receive: www.peachpit.com/u.aspx.

Sale of Personal Information


Pearson does not rent or sell personal information in exchange for any payment of money.

While Pearson does not sell personal information, as defined in Nevada law, Nevada residents may email a request for no sale of their personal information to NevadaDesignatedRequest@pearson.com.

Supplemental Privacy Statement for California Residents


California residents should read our Supplemental privacy statement for California residents in conjunction with this Privacy Notice. The Supplemental privacy statement for California residents explains Pearson's commitment to comply with California law and applies to personal information of California residents collected in connection with this site and the Services.

Sharing and Disclosure


Pearson may disclose personal information, as follows:

  • As required by law.
  • With the consent of the individual (or their parent, if the individual is a minor)
  • In response to a subpoena, court order or legal process, to the extent permitted or required by law
  • To protect the security and safety of individuals, data, assets and systems, consistent with applicable law
  • In connection the sale, joint venture or other transfer of some or all of its company or assets, subject to the provisions of this Privacy Notice
  • To investigate or address actual or suspected fraud or other illegal activities
  • To exercise its legal rights, including enforcement of the Terms of Use for this site or another contract
  • To affiliated Pearson companies and other companies and organizations who perform work for Pearson and are obligated to protect the privacy of personal information consistent with this Privacy Notice
  • To a school, organization, company or government agency, where Pearson collects or processes the personal information in a school setting or on behalf of such organization, company or government agency.

Links


This web site contains links to other sites. Please be aware that we are not responsible for the privacy practices of such other sites. We encourage our users to be aware when they leave our site and to read the privacy statements of each and every web site that collects Personal Information. This privacy statement applies solely to information collected by this web site.

Requests and Contact


Please contact us about this Privacy Notice or if you have any requests or questions relating to the privacy of your personal information.

Changes to this Privacy Notice


We may revise this Privacy Notice through an updated posting. We will identify the effective date of the revision in the posting. Often, updates are made to provide greater clarity or to comply with changes in regulatory requirements. If the updates involve material changes to the collection, protection, use or disclosure of Personal Information, Pearson will provide notice of the change through a conspicuous notice on this site or other appropriate way. Continued use of the site after the effective date of a posted revision evidences acceptance. Please contact us if you have questions or concerns about the Privacy Notice or any objection to any revisions.

Last Update: November 17, 2020