Cover | Table of Contents | Colophon
box.
width and height attributes of the <embed> or <object> tags, but this can have unexpected results, such as an elongated or distorted appearance. Also, if your movie contains bitmap images, they can appear grainy as a result of being stretched. Bitmaps should always be brought into Flash at the largest dimensions needed for the movie. Bitmaps that are scaled down maintain a high-quality look, but enlarging a bitmap in Flash makes it look pixelated.http://www.flipflopflyin.com/boymeetspixel).
object> and <embed> tags). That allows you to publish a .swf as an element on an HTML page along with other content. That said, sometimes you'll want the .swf file to be the only thing on the page and to fill the browser window.
stop(); on frame 60. This causes the main timeline to stop animating once frame 60 is reached. As a best practice, you should include the semicolon after stop() to signify the end of the command. In simple cases such as this, the semicolon is optional because Flash can guess where the end of the command is (as indicated by the carriage return at the end of the line). But commands can be split onto multiple lines, making it harder for Flash to guess where the command ends, so it is good practice to include the semicolon at the end of each command. As a general rule, if a command is broken onto multiple lines, the semicolon belongs at the end of the last line. We'll talk more about semicolons in Chapter 7.legs_mcclip has its own independent timeline. Press Enter or Return to insert a blank line in the Script pane and add the following ActionScript to make the legs stop moving: box_guy _mc.legs_mc.stop();.legs_mc instance located inside the box_guy_mc instance.box_guy_mc):
box_guy_mc.onPress = function () {
gotoAndPlay(1);
};
box_guy_mc.onPress = function () {
gotoAndPlay(1);
this.legs_mc.play();
box_guy_mc clip in the movie.http://www.apple.com/quicktime to download and install it. Don't worry—although QuickTime Pro costs $29.99, the free version is sufficient for our needs. Leave your credit card in your wallet.http://www.2advanced.com) and many others, so get ready to use some cool Flash design techniques.http://www.americansplendormovie.com), where a set of panels for a comic strip is drawn right in front of you and filled with images. This can be done with motion tweens, but it would involve using masks, which we'll talk about in Chapter 10, and would be more complicated than it needs to be. The solution?
Shape tweens.