Macromedia Using Director MX User Manual

5 (1)

Using Director MX

Macromedia Director MX

Trademarks

Afterburner, AppletAce, Attain, Attain Enterprise Learning System, Attain Essentials, Attain Objects for Dreamweaver, Authorware, Authorware Attain, Authorware Interactive Studio, Authorware Star, Authorware Synergy, Backstage, Backstage Designer, Backstage Desktop Studio, Backstage Enterprise Studio, Backstage Internet Studio, Contribute, Design in Motion, Director, Director Multimedia Studio, Doc Around the Clock, Dreamweaver, Dreamweaver Attain, Drumbeat, Drumbeat 2000, Extreme 3D, Fireworks, Flash, Fontographer, FreeHand, FreeHand Graphics Studio, Generator, Generator Developer’s Studio, Generator Dynamic Graphics Server, Knowledge Objects, Knowledge Stream, Knowledge Track, Lingo, Live Effects, Macromedia, Macromedia Contribute, Macromedia M Logo & Design, Macromedia Flash, Macromedia Xres, Macromind, Macromind Action, MAGIC, Mediamaker, Object Authoring, Power Applets, Priority Access, Roundtrip HTML, Scriptlets, SoundEdit, ShockRave, Shockmachine, Shockwave, Shockwave Remote, Shockwave Internet Studio, Showcase, Tools to Power Your Ideas, Universal Media, Virtuoso, Web Design 101, Whirlwind and Xtra are trademarks of Macromedia, Inc. and may be registered in the United States or in other jurisdictions including internationally. Other product names, logos, designs, titles, words or phrases mentioned within this publication may be trademarks, servicemarks, or tradenames of Macromedia, Inc. or other entities and may be registered in certain jurisdictions including internationally.

This guide contains links to third-party Web sites that are not under the control of Macromedia, and Macromedia is not responsible for the content on any linked site. If you access a third-party Web site mentioned in this guide, then you do so at your own risk. Macromedia provides these links only as a convenience, and the inclusion of the link does not imply that Macromedia endorses or accepts any responsibility for the content on those third-party sites.

Apple Disclaimer

APPLE COMPUTER, INC. MAKES NO WARRANTIES, EITHER EXPRESS OR IMPLIED, REGARDING THE ENCLOSED COMPUTER SOFTWARE PACKAGE, ITS MERCHANTABILITY OR ITS FITNESS FOR ANY PARTICULAR PURPOSE. THE EXCLUSION OF IMPLIED WARRANTIES IS NOT PERMITTED BY SOME STATES. THE ABOVE EXCLUSION MAY NOT APPLY TO YOU. THIS WARRANTY PROVIDES YOU WITH SPECIFIC LEGAL RIGHTS. THERE MAY BE OTHER RIGHTS THAT YOU MAY HAVE WHICH VARY FROM STATE TO STATE.

Copyright © 2002 Macromedia, Inc. All rights reserved. This manual may not be copied, photocopied, reproduced, translated, or converted to any electronic or machine-readable form in whole or in part without prior written approval of Macromedia, Inc.

Third Party Software Notices and/or Additional Terms and Conditions can be found at http://www.macromedia.com/go/ thirdparty/.

Part Number ZDR90M100

Acknowledgments

Writing: Jay Armstrong, George Brown, Stephanie Gowin, and, Tim Statler

Editing: Rosana Francescato, Mary Ferguson, Mary Kraemer, and Noreen Maher

Project Management: Stuart Manning

Production: Chris Basmajian, Caroline Branch, John Francis, and Patrice O’Neill

Multimedia: Aaron Begley and Benjamin Salles

First Edition: December 2002

Macromedia, Inc.

600 Townsend St.

San Francisco, CA 94103

CONTENTS

INTRODUCTION

Getting Started . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13

System requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 Installing Director . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 What’s new in Director MX . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 Resources for learning Director . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16 Conventions used in Director Help and printed books . . . . . . . . . . . . . . . . . . . . . . . . . 18

CHAPTER 1

Director Basics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19

Creating a new movie . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 Introducing the Director workspace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 Managing the workspace in Director MX . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34 Using multiple Score windows. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 Changing Score settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 Using markers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 Selecting and editing frames in the Score. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 About adding interactivity with Lingo. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 Converting movies created in previous versions of Director. . . . . . . . . . . . . . . . . . . . . . 45 Managing the Director authoring environment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45 About using Xtra extensions to extend Director functionality . . . . . . . . . . . . . . . . . . . . 50 About distributing movies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51 Answers panel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52

CHAPTER 2

Director MX Basics Tutorial . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53

What you’ll learn. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53 About the Director metaphor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54 View the completed movie . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 Open the tutorial movie . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 Set up the movie . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56 View your cast members . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58 Edit a text cast member . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59 Build the first scene . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60 Edit sprites in the Score window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64 Create an animation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66 Change the tempo of an animation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75 Create a sunset animation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75

3

Add navigation buttons to the animation scene . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77 Build the sound and video scene . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79 Write Lingo scripts to control movie playback. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 88 Add Lingo to navigation buttons. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92 Write Lingo that refers to scenes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 93 About controlling video in Director . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94 Add scripts for video control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 95 Control sound with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97 Add sounds to buttons . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98 Publish your movie for the web . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99 Continue learning about Director . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 102

CHAPTER 3

Director MX 3D Tutorial . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 103

What you’ll learn. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 103 What you should know . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 103 View the completed movie . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 104 Open the tutorial movie . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 104 Create 3D text. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 104 Modify behaviors. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 111 View a 3D world . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 112 Use the camera . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 112 Set model rollover cursors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 121 Use 3D behaviors for navigation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 122 Play your completed movie . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 125 To learn more . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 126

CHAPTER 4

Cast Members and Cast Windows . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 127

Creating new casts. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 128 Creating cast members . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 130 Using the Cast window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 131 Naming cast members . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 136 Using Cast List view . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 136 Using Cast Thumbnail view . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 137 Moving cast members within the Cast window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 139 Organizing cast members within the Cast window . . . . . . . . . . . . . . . . . . . . . . . . . . . 139 Setting Cast window preferences . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 140 Changing Cast properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 142 Viewing and setting cast member properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 142 Finding cast members . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 144 Importing cast members . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 146 Launching external editors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 151 Managing external casts. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 153 Creating libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 154 Setting cast member properties using Lingo. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 154 Setting Xtra cast member properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 155

4Contents

CHAPTER 5

Sprites . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 157

Creating sprites . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 157 Changing sprite preferences. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 158 Selecting sprites . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 158 Layering sprites . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 161 Displaying and editing sprite properties. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 161 Locking and unlocking sprites . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 167 Positioning sprites . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 167 Changing the appearance of sprites . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 175 Using sprite inks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 180 Assigning a cast member to a sprite with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 184

CHAPTER 6

Animation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 185

About tweening in Director. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 186 Tweening the path of a sprite. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 186 Accelerating and decelerating sprites . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 188 Tweening other sprite properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 188 Suggestions and shortcuts for tweening . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 190 Changing tweening settings. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 190 Switching a sprite’s cast members. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 191 Editing sprite frames . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 192 Frame-by-frame animation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 193 Shortcuts for animating with multiple cast members . . . . . . . . . . . . . . . . . . . . . . . . . . 195 Using film loops . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 197 Setting film loop properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 198 Step-recording animation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 199 Real-time recording animation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 200 Linking a sequence with Paste Relative . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 201 Animating sprites with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 201

CHAPTER 7

Bitmaps . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 203

About importing bitmaps . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 204 Using animated GIFs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 205 Using the Paint window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 206 Changing selected areas of a bitmap . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 214 Flipping, rotating, and applying effects to bitmaps . . . . . . . . . . . . . . . . . . . . . . . . . . . 215 Using Auto Distort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 218 Changing registration points . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 219 Changing size, color depth, and color palette for bitmaps . . . . . . . . . . . . . . . . . . . . . . 220 Controlling bitmap images with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 222 Using gradients . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 224 Using patterns . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 228 Creating a custom tile . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 229 Using Paint window inks. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 229 Using bitmap filters. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 232 Using onion skinning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 234 About the Paste as Pict option . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 236

Contents 5

Setting bitmap cast member properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 237 Setting PICT cast member properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 238 Setting Paint window preferences . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 238 Compressing bitmaps . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 239 Working with Macromedia Fireworks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 240

CHAPTER 8

Vector Shapes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 245

Drawing vector shapes. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 245 Editing vector shapes. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 249 Defining gradients for vector shapes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 251 Controlling vector shapes with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 252 Setting vector shape properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 252 Using shapes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 253 Setting shape cast member properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 254

CHAPTER 9

Color, Tempo, and Transitions. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 255

Controlling color. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 255 Setting palette cast member properties. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 266 About tempo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 267 Using transitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 270

CHAPTER 10

Text . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 273

Embedding fonts in movies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 274 Creating text cast members . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 275 Editing and formatting text . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 276 Creating a hypertext link . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 282 Working with fields . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 282 Using editable text. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 283 Converting text to a bitmap . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 284 Mapping fonts between platforms for field cast members . . . . . . . . . . . . . . . . . . . . . . 284 Setting text or field cast member properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 285 Formatting chunks of text with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 288 Formatting text or field cast members with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . 289 Controlling scrolling text with Lingo. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 290 Checking for specific text with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 290 Modifying strings with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 291

6Contents

CHAPTER 11

Using Flash and Other Interactive Media Types. . . . . . . . . . . . . . . . . . . . . . 293

Using Flash Movies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

293

Editing a Flash cast member . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

296

Controlling a Flash movie with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

297

Controlling a Flash movie’s appearance with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . .

297

Streaming Flash movies with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

300

Playing back Flash movies with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

300

Using Lingo to set and test Flash variables. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

301

Sending Lingo instructions from Flash movies. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

302

Using Flash objects in Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

304

Using the Flash local connection object . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

306

Using Flash Communication Server MX . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

309

Using the Flash Settings panel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

311

Playback performance tips for Flash movies. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

312

Using Director movies within Director movies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

313

Setting linked Director movie properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

314

Using ActiveX controls . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

316

CHAPTER 12

Sound and Synchronization. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 319

Importing internal and linked sounds . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 320 Setting sound cast member properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 321 Controlling sound in the Score . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 321 Looping a sound . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 322 Using sound in Windows . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 323 Playing sounds with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 323 About Shockwave Audio . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 325 Compressing internal sounds with Shockwave Audio . . . . . . . . . . . . . . . . . . . . . . . . . 326 Streaming linked Shockwave Audio and MP3 audio files. . . . . . . . . . . . . . . . . . . . . . . 326 Playing Shockwave Audio and MP3 audio with Lingo . . . . . . . . . . . . . . . . . . . . . . . . 327 Synchronizing media . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 328 Synchronizing sound with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 329 Accessibility. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 329

CHAPTER 13

Using Video . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 331

Importing digital video . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 332 Using the Video window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 332 Setting digital video cast member properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 333 Playing digital video direct-to-Stage. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 334 Controlling digital video in the Score . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 335 Playing digital video with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 336 Controlling QuickTime with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 337 Cropping digital video. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 339 About using digital video on the Internet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 340 Preloading AVI digital video . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 341 Synchronizing video and animation. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 341 Using RealMedia content in Director . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 341 Using Lingo sound elements with RealMedia . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 354

Contents 7

CHAPTER 14

Behaviors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 357

Attaching behaviors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 357 Changing the order of attached behaviors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 360 Getting information about behaviors. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 361 Creating and modifying behaviors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 361 Writing behaviors with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 365 Setting up a Parameters dialog box . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 365 Setting behavior properties with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 366 Customizing a behavior’s property. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 366 Creating an on getPropertyDescriptionList handler . . . . . . . . . . . . . . . . . . . . . . . . . . . 367 Including a description for the Behavior inspector. . . . . . . . . . . . . . . . . . . . . . . . . . . . 368 Example of a complete behavior . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 369 Sending messages to behaviors attached to sprites . . . . . . . . . . . . . . . . . . . . . . . . . . . . 369 Using inheritance in behaviors. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 371

CHAPTER 15

Navigation and User Interaction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 373

Creating basic navigation controls with behaviors . . . . . . . . . . . . . . . . . . . . . . . . . . . . 374 Adding push buttons, radio buttons, and check boxes . . . . . . . . . . . . . . . . . . . . . . . . . 374 Jumping to locations with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 375 Detecting mouse clicks with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 377 Making sprites editable and draggable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 377 Making sprites editable or moveable with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 378 Checking which text is under the pointer with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . 379 Responding to rollovers with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 379 Finding mouse pointer locations with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 380 Checking keys with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 380 Equivalent cross-platform keys . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 380 Identifying keys on different keyboards . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 381 About animated color cursors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 381 Creating an animated color cursor cast member . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 382 Using an animated color cursor in a movie . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 384

CHAPTER 16

Writing Scripts with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 385

Scripting basics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 385 Lingo terminology. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 389 Lingo syntax . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 390 Writing Lingo statements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 392 Using handlers. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 396 Using lists . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 398 Expressing literal values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 404 Using operators to manipulate values. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 408 Controlling flow in scripts. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 410 Creating and attaching scripts with the Script window . . . . . . . . . . . . . . . . . . . . . . . . 412 Using linked scripts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 416 Using parent scripts and child objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 417 Troubleshooting Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 426

8Contents

CHAPTER 17

3D Basics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 443

What you need to know . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 443 From 2D to 3D. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 444 The 3D Xtra . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 446 Using the Shockwave 3D window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 446 Using the Property inspector for 3D . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 448 Using rendering methods . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 449 Using 3D Anti-aliasing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 450 3D behaviors. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 452 3D text . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 452 The 3D world . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 452

CHAPTER 18

The 3D Cast Member, 3D Text, and 3D Behaviors . . . . . . . . . . . . . . . . . . 455

About the 3D cast member . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 455 Model resources. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 456 Models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 458 Shaders . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 458 Textures. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 459 Motions. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 460 Lights . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 460 Cameras . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 461 Groups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 462 Creating 3D text . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 462 Modifying 3D text . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 463 Lingo for 3D text . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 464 Using 3D behaviors. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 466

CHAPTER 19

Working with Models and Model Resources. . . . . . . . . . . . . . . . . . . . . . . . . 473

About models and model resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 473 Model resources. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 473 Primitives . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 474 Cast member commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 481 Models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 482 Shaders . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 487 Textures. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 494 Groups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 496 Modifiers. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 498 Animation modifiers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 502 Motions. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 510 About lights and cameras. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 511 Light properties. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 512 Light commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 513 Cameras . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 515

Contents 9

CHAPTER 20

Controlling the 3D World . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 521

3D Lingo events . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 521 Collisions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 522 Vector math. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 524 Transforms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 526 Rendering functionality. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 530

CHAPTER 21

Movies in a Window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 537

Creating a MIAW using Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 538 Opening and closing a MIAW. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 538 Setting the window type for a MIAW . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 539 Setting the window size and location for a MIAW . . . . . . . . . . . . . . . . . . . . . . . . . . . . 540 Cropping and scaling a MIAW . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 540 Controlling the appearance of a MIAW. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 541 Listing the current movies in windows. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 541 Controlling interaction between MIAWs. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 542 Controlling events involving MIAWs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 542

CHAPTER 22

Using the XML Parser Xtra. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 543

About XML . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 543 Using XML parser objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 544 Using XML document nodes. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 545 Accessing attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 548 Parser objects and XML nodes. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 548 Treating white space . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 549 XML and character sets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 549

CHAPTER 23

Making Director Movies Accessible . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 551

About government requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 551 Making Director movies accessible . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 551 Using the Accessibility behavior library . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 552 Using accessibility Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 559 Deploying accessible movies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 560

CHAPTER 24

Managing Memory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 563

How Director unloads items from memory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 563 Loading and unloading individual cast members . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 564 Preloading digital video . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 565

CHAPTER 25

Managing and Testing Director Projects . . . . . . . . . . . . . . . . . . . . . . . . . . . . 567

Managing Director projects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 567 About testing movies to avoid problems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 568

10 Contents

CHAPTER 26

Packaging Movies for Distribution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 571

Shockwave browser compatibility . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 571 Previewing a movie in a browser . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 572 About Xtra extensions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 572 Managing Xtra extensions for distributed movies . . . . . . . . . . . . . . . . . . . . . . . . . . . . 574 About distribution formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 574 Creating Shockwave movies. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 576 Setting movie options for browser resizing. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 580 About projectors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 582 Creating projectors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 582 Processing movies with Update Movies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 585 Exporting digital video and frame-by-frame bitmaps . . . . . . . . . . . . . . . . . . . . . . . . . . 586 Setting QuickTime export options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 588 About organizing movie files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 590

CHAPTER 27

Using Shockwave Player . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 591

About streaming movies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 591 About network operations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 592 Setting movie playback options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 592 Setting Shockwave playback options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 593 About creating multiuser applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 594 About streaming with the Score and behaviors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 594 Checking whether media elements are loaded with Lingo . . . . . . . . . . . . . . . . . . . . . . 595 Downloading files from the Internet with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 596 Retrieving network operation results with Lingo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 597 Using Lingo in different Internet environments. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 598 Testing your movie . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 601 About downloading speed . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 601

INDEX. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 603

Contents 11

12 Contents

INTRODUCTION

Getting Started

Macromedia Director MX is the world’s foremost authoring tool for creating interactive multimedia. Developers rely on Director to create attention-grabbing business presentations, advertising kiosks, interactive entertainment, and educational products. To see some of the exciting and varied ways in which developers use Director, visit the Director showcase at www.macromedia.com/software/director/special/inspiration/. You can also see great examples of Shockwave at www.shockwave.com.

Your users can view your completed Director movie over the Internet, either in a web browser or independent of a browser,or in a stand-alone projector suitable for LANs and distribution through CD-ROM and DVD-ROM.

System requirements

The following hardware and software are the minimum required to author Director movies:

For Microsoft Windows: An Intel Pentium II 200 processor running Windows 98, 2000, or XP; 128 MB of available RAM plus 100 MB of available disk space; a color monitor; and a CD-ROM drive

For the Macintosh: A Power Macintosh G3 running System 10.1 or later; 128 MB of available RAM plus 100 MB of available disk space; a color monitor; and a CD-ROM drive

The following hardware and software are the minimum required to play back Director movies:

For Microsoft Windows: An Intel Pentium II 200 processor running Windows 95/98, 2000, XP, or NT version 4.0 or later; 32 MB of installed RAM; Netscape Navigator 4.0 or later, Microsoft Internet Explorer 4.0 or later, or America Online 4.0 or later web browser; and a color monitor

For the Macintosh OS X: A Power Macintosh G3 running System 10.1 or later; 128 MB of available RAM; Microsoft Internet Explorer 5.1 or later; and a color monitor

For the Macintosh Classic operating system: A Power Macintosh 180 (G3 recommended) running System 8.6 or later; 32 MB of installed RAM; Netscape 4.0 or later, Microsoft Internet Explorer 4.5 or later, or America Online 4.0 or later web browser; and a color monitor

13

Installing Director

Follow these steps to install Director on either a Windows or a Macintosh computer.

To install Director on a Windows or a Macintosh computer:

1 Insert the Director CD into the computer’s CD-ROM drive and do one of the following:

In Windows, if the installation program doesn’t start automatically, choose Run from the Windows Start menu, type d:\setup.exe (where d is your CD-ROM drive letter), and click OK.

On the Macintosh, double-click the Director Installer icon.

2 Follow the onscreen instructions.

3 If prompted, restart your computer.

What’s new in Director MX

New features in Director MX build on a proven development environment to make Director more powerful, more tightly integrated with the Macromedia MX product family, and better suited to create content that is accessible to everyone, even those with disabilities.

Developers can deliver rich multimedia content that integrates interactive audio, video, bitmaps, vectors, text, fonts, and more. Director MX lets you work more effectively with the shared Macromedia MX user interface, take advantage of unprecedented Macromedia Flash MX integration, and deliver content to a broader audience.

Integration with other Macromedia MX products

Director MX is truly a part of the Macromedia MX family; this is evident in the workspace, which matches those of other Macromedia MX products, as well as in other aspects of the application’s strong integration with Macromedia Flash MX, ColdFusion MX, Flash Communications Server MX, and other Macromedia MX products.

The Macromedia MX workspace lets you organize and customize an environment that’s shared among Dreamweaver MX, Fireworks MX, and Macromedia Flash MX. The familiar and flexible working environment helps you maximize productivity. Dockable panels can be grouped and collapsed or expanded as needed for a smooth workflow.

Enhanced control of Macromedia Flash media through Lingo gives you complete access to all

properties and methods of Flash MX ActionScript objects. Greatly reduce your development time by directly controlling all elements within your content that were authored in Flash MX.

Access to the Flash MX launch-and-edit feature lets you simply double-click a SWF file to

automatically launch Flash MX. Once you edit the file, it’s automatically saved and reimported into Director MX. This roundtrip editing significantly streamlines your workflow.

Macromedia Flash Communication Server MX support allows you to use all the functional

capabilities provided by Flash Communication Server MX, including the ability to access installed USB or FireWire cameras as well as installed microphones. You can combine the power of the Flash Communication Server MX with Director MX to create multiuser games, distancelearning applications, and real-time collaboration forums. Previous users of the Shockwave Multiuser Server are encouraged to use Flash Communication Server MX. However, the Shockwave Multiuser Server is available on the Director installation CD.

14 Introduction

Macromedia Flash MX importing

lets you take advantage of the power of Flash MX and its lightweight vector graphics by importing Flash files into Director MX content. Director developers can use this powerful combination to create the most effective multimedia content.

Macromedia Flash Remoting MX provides a secure, high-performance connection between Macromedia ColdFusion MX and Shockwave Player. When used with Director MX, Flash Remoting MX lets you easily pass data to ColdFusion MX and back.

Macromedia Fireworks MX integration gives Director MX developers access to the robust design and production environment of Fireworks MX, allowing developers to create graphics for presentations or Shockwave content. In addition, the tight integration between Fireworks MX and Director MX offers a roundtrip workflow between these graphic and multimedia environments. Integration features include launching and editing, Fireworks MX importing, launching and optimizing, and the Fireworks MX Import Xtra.

Accessible content

Director MX allows you to create content that meets internationally recommended guidelines and government accessibility requirements—including Section 508 guidelines. Director MX lets you add text-to-speech, captioning, and tab-navigation features to web-based Shockwave content or stand-alone applications on both Microsoft Windows and Apple Macintosh systems.

The cross-platform Speech Xtra makes Director MX applications “self-voicing”—that is, text is converted to speech without a screen reader. The user’s operating system provides voices at the system level. You can create completely customizable, accessible content that doesn’t rely on screen readers. Any user with Shockwave Player and an installed speech engine (which ships with current operating systems) can then use your accessible content.

Drag-and-drop accessibility behaviors in Director MX let you easily control speech and tab ordering, as well as synchronize text with spoken words, in order to repurpose existing Director applications to adhere to accessibility guidelines.

Enhanced power of Director

Director MX introduces many new features that improve on the renowned power of Director to create rich media multimedia content that can be deployed on CDs, DVDs, or corporate intranets—or to more than 300 million web users with Shockwave Player.

Advanced debugging capabilities enhance the power of Lingo, the object-oriented Director programming language. Director MX offers a streamlined professional debugging layout, with everything you need in one convenient place.

The unified Script and Debugger windows let you debug, browse, and edit scripts all in the same window. The Script window switches to debugging mode when a Lingo error or a breakpoint is encountered. You can edit scripts while in debugging mode.

New Script window buttons save you development time when you’re working in Lingo. Among the buttons are a button that lets you inspect and debug code faster and realize better input responses when editing large files, a button that pinpoints debugging issues more quickly when working with others, and a button that organizes 3D Lingo commands separately from other Lingo commands for faster 3D debugging.

The Scripting Xtras window helps you organize your third-party scripting Xtra extensions more efficiently. The window detects all installed scripting Xtra extensions, gets their methods and properties, and organizes them in a convenient pop-up menu.

Getting Started 15

An Object inspector with data browser functionality lets you inspect all properties of script

instances, and examine the hierarchy of elements inside 3D cast members and Flash MX sprites. The ability to quickly examine and modify all your movie components reduces both debugging and development time.

Color-coding of recently changed variables makes tracking changes quick and easy with

immediate visual feedback. As you step through your code, the Debugger window displays the variables whose values have changed in red.

The split-paned Message window shows you the results of your code changes immediately. Now movies can execute and display information in the Output pane while you enter and execute Lingo commands in the Input pane.

QuickTime 6 support allows you to take advantage of QuickTime 6 features, including support for streaming MPEG4 video and MP3 audio.

Macintosh OS X support lets you create Director MX content using Mac OS X, the modern Apple operating system. You can author in Mac OS X and create Shockwave applications and executables that can be viewed on Mac OS X as well as pre–Mac OS X systems.

Resources for learning Director

The Director package contains a variety of media to help you learn the program quickly and become proficient in creating multimedia—including the printed books Using Director MX and

Director MX Lingo Dictionary, both of which are also available as online help. Using Director MX contains two tutorials. The Director MX workspace contains tooltips and context-sensitive help, and additional help is available on the Director MX website at www.macromedia.com/support/ director. The new Answers panel in the Director workspace gives you a quick and easy way to find out about the latest Director materials available on the web.

Director Help

Director Help is the comprehensive information source for all Director features. The help system includes complete conceptual overviews of all features, animated examples, descriptions of all interface elements, and a reference of all Lingo commands and elements. Topics are extensively cross-referenced and indexed to make finding information and jumping to related topics quick and easy.

You can access Director Help from the Help menu. To access context-sensitive help, select Help from the Options menu for any panel, palette, or inspector, or click the Help button in any dialog box.

Director MX tutorials

When you’re ready to start working in Director, begin with Chapter 2, “Director MX Basics Tutorial,” on page 53. The tutorial shows you how to create a basic movie using some of the most useful and powerful features of Director.

If you want to produce 3D content, see Chapter 3, “Director MX 3D Tutorial,” on page 103.

Using Director MX manual

This printed manual contains all the information found in Director Help.

16 Introduction

Director MX Lingo Dictionary

The Director MX Lingo Dictionary is a printed version of all the Lingo topics in Director Help.

Answers panel

The Answers panel provides quick access to information that helps you work effectively with Director. This includes tutorials, TechNotes, and other useful content.

You can get the latest Director information from macromedia.com by simply clicking the Update button in the Answers panel.

Tooltips

When you place the pointer over a Director tool or other workspace feature for a few seconds, a small tooltip appears that explains the function of the item.

Keyboard shortcuts

Many commands that are available from Director menus are also accessible through keyboard shortcuts. When you display a menu or submenu, the appropriate key combinations are shown next to the commands for which keyboard shortcuts are available.

The following illustration shows key board shortcuts for a variety of commands on the Control menu. (The illustration shows Director running on Windows. When Director is running on a Macintosh, the keyboard shortcuts reflect Macintosh keys.)

Director Support Center

The Director Support Center website (www.macromedia.com/support/director/) contains the latest information on Director, plus additional topics, examples, tips, and updates. Check the website often for the latest news on Director and how to get the most out of the program.

Getting Started 17

Conventions used in Director Help and printed books

The help system and printed books use the following conventions:

The terms Lingo and Director refer to Director MX.

Within the text and in Lingo examples, Lingo elements and parts of actual code are shown in

this font. For example, set answer = 2 + 2 is a sample Lingo statement.

Quotation marks that are part of Lingo statements are shown in the text and Lingo code examples as straight quotation marks (") rather than as curly quotation marks (”).

The continuation symbol (¬), which you enter by pressing Alt+Enter (Windows) or Option+Return (Macintosh), indicates that a long line of Lingo has been broken onto two or more lines. Lines of Lingo that are broken this way are not separate lines of code. When you see the continuation symbol in this book, type the lines as one line when you enter them in the Script window.

Variables used to represent parameters in Lingo appear in italics. For example, whichCastMember is commonly used to indicate where you insert the name of a cast member in Lingo.

Text that you should type is shown in this font.

18 Introduction

CHAPTER 1

Director Basics

Macromedia Director MX is the tool of choice for legions of web and multimedia developers. With Director, you can create movies for websites, kiosks, and presentations as well as movies for education and entertainment. Movies can be as small and simple as an animated logo or as complex as an online chat room or game. Director movies can include a variety of media, such as sound, text, graphics, animation, and digital video. A Director movie can link to external media or be one of a series of movies that refer to one another.

Your users view completed Director movies in one of the following ways:

In the Macromedia Shockwave movie format, which plays in Shockwave-enabled web browsers. Millions of web users already have the Shockwave Player on their computers, browsers, or system software. Others have downloaded Shockwave Player, which is free, from Macromedia’s website at www.macromedia.com/shockwave/download/.

In a projector, which plays on your user’s computer as a stand-alone application.

Creating a new movie

Director is organized around a movie metaphor.

To create a new movie:

Select File > New > Movie.

19

Introducing the Director workspace

When you first launch Director, there are several windows in the default layout, including the Stage, the Score, the Cast, and the Property inspector.

Tools

Stage

Property inspector

Cast

Score

Default Director MX window layout (Windows platform)

When creating and editing a movie, you typically work in four of these windows: the Stage, the Score, the Cast, and the Property inspector.

The Stage

If the Stage is not open, select Window > Stage.

The Stage is the visible portion of a movie on which you determine where your media elements appear.

During authoring, you have the ability to define the properties of your Stage, such as its size and color. As you work on your movie, you can use zooming to make the Stage either larger or smaller than the original movie, while also scaling the coordinates for the Stage objects. To align objects on the Stage, you can select to display guides and grids or use the Align window.

20 Chapter 1

To scroll around the Stage, do one of the following:

Use the scroll bars. (To show or hide Stage scroll bars, select Edit > Preferences > General and select or deselect Show Stage Scrollbars.)

Select the Hand tool from the Tool palette and drag inside the Stage to reposition the visible portion.

Bring the Stage to the front, hold down the Spacebar to temporarily switch to the Hand tool, and then drag inside the Stage to reposition the visible portion.

Title bar

Canvas area

Scroll bars

Control panel

The Control panel

The Control panel governs how movies play back in the authoring environment. To go to a specific frame number in a movie, enter the number in the frame counter, and press Enter (Windows) or Return (Macintosh). You can also use the toolbar buttons or keyboard shortcuts to play a movie.

By default, the Control panel is attached to the bottom of the Stage. You can turn it into a floating panel by detaching it.

To detach the Control panel from the Stage, do one of the following:

Right-click (Windows) or Control-click (Macintosh) the Control panel. In the context menu, select Detach Control Panel.

Right-click (Windows) or Control-click (Macintosh) the Property inspector or Tool palette. In the context menu, select Detach Control Panel.

Director Basics 21

The floating (detached) Control panel displays tempo information that does not appear when the Control panel is attached to the Stage. For more information about tempo, see “About tempo” on page 267.

Actual tempo

Tempo Setting

The floating Control panel

To close the floating Control panel, do one of the following:

Select Window > Control Panel.

Press Control+2 (Windows) or Command+2 (Macintosh).

Note: After you close the floating Control panel, you can use these same instructions to reopen it. However, you cannot close a Control panel when it is attached to the Stage; you can only detach it.

To reattach the floating Control panel to the Stage, do one of the following:

Right-click (Windows) or Control-click (Macintosh) the Control panel. In the context menu, select Attach Control Panel.

Right-click (Windows) or Control-click (Macintosh) the Property inspector or Tool palette. In the context menu, select Attach Control Panel.

The Score

If the Score is not visible, select Window > Score.

The Score organizes and controls a movie’s content over time in rows that contain the media, called channels. The Score includes special channels that control the movie’s tempo, sound, and color palettes. The Score also includes frames and the playhead. You use the Score to assign scripts—Lingo instructions that specify what the movie does when certain events occur in

the movie.

22 Chapter 1

Macromedia Using Director MX User Manual

You can control the Score by zooming to reduce or magnify your view and by displaying multiple Score windows. You can also control the Score’s appearance by selecting Edit > Preferences > Score.

Score Playhead

Keyframe

Sprite in Score

The Cast window

If the Cast window is not visible, select Window > Cast.

In the Cast window, you can view your cast members, which are the media in your movie, such as sounds, text, graphics, and other movies. Cast members can also include assets that you use in your Score but not on the Stage, such as scripts, palettes, fonts, and transitions. You can create cast members in Director, and you can import existing media to include in your cast. The Cast window lets you view your cast members as a list or as thumbnails, depending on your preference.

23 Chapter 1

The Property inspector

If the Property inspector is not visible, select Window > Property Inspector.

The Property inspector provides a convenient way to view and change attributes of any selected object, or multiple objects, in your movie. After you select an object, relevant category tabs and associated fields appear in the Property inspector. If you select multiple objects, only the information that is common to all the selected objects appears.

The List View Mode icon in the Property inspector lets you toggle between a List and a Graphical view.

List View Mode icon

24 Chapter 1

The following illustrations show different information that appears in the Property inspector, depending on what is selected. In the first illustration, a sprite is selected. In the second illustration, a cast member is selected.

To show more or less information in the Property inspector:

Click the expander arrow in the Property inspector.

Director Basics 25

The following illustrations show different information appearing in the Property inspector depending on whether the expanded information is hidden or shown.

26 Chapter 1

Setting Stage and movie properties

You use the Property inspector’s Movie tab to specify settings that affect the entire movie, such as how colors are defined, the size and location of the Stage, the number of channels in the Score, copyright information, and font mapping. These settings apply only to the current movie, whereas the settings you select from Edit > Preferences apply to every movie.

To set Stage and movie properties:

1 Click the Movie tab in the Property inspector in Graphical view.

2To define the size of the Stage, select a preset value from the Stage Size pop-up menu or enter values in the Width and Height fields.

3To specify the location of the Stage during playback if the movie does not take up the full screen, select an option from the Location pop-up menu or enter values for Left and Top; these values specify the number of pixels the Stage is placed from the upper left corner of the screen, and they apply only if the Stage is smaller than the current monitor’s screen size.

Centered places the Stage window in the center of your monitor. This option is useful if you play a movie that was created for a 13-inch screen on a larger screen or if you’re creating a movie on a large screen that will be seen on smaller screens.

Upper Left places the Stage in the upper left corner of the screen.

4 To specify the number of channels in the Score, enter a value for Channels.

5To set the color of the Stage for the movie, click the color box next to Color and select a color, or enter an RGB value in the text box on the right.

Director Basics 27

6To select a color palette for the movie, select a palette from the Palette pop-up menu. This palette remains selected until Director encounters a different palette setting in the Palette channel.

For a complete discussion of color palettes and using color in Director, see “Controlling color” on page 255.

7To determine how the movie assigns colors, select either RGB or Palette Index.

RGB makes the movie assign all color values as absolute RGB values.

Palette Index makes the movie assign color according to its position in the current palette.

8To let users cut, copy, and paste editable fields while a movie is playing, select Enable Edit Shortcuts.

9To select a default renderer used to draw 3D sprites within the movie, if that renderer is available on the client computer, select one of the following options from the Preferred 3D Renderer pop-up menu:

OpenGL specifies the openGL drivers for hardware acceleration that work with Macintosh and Windows platforms.

DirectX 7.0 specifies the DirectX 7 drivers for hardware acceleration that work only with Windows platforms.

DirectX 5.2 specifies the DirectX 5.2 drivers for hardware acceleration that work only with Windows platforms.

Software specifies Director’s built-in software renderer that works with Macintosh and Windows platforms.

Auto specifies that the most suitable renderer should be selected. This option is the default value for this property.

Note: If the preferred renderer is not available on the client computer, the movie selects the most suitable available renderer.

10To enter copyright and other information about the movie, enter text in the About and Copyright text boxes.

This information is important if your movie will be downloaded from the Internet and saved on a user’s system.

11To save the current font map settings in a text file named Fontmap.txt, click Save. To load the font mapping assignments specified in the selected font map file, click Load. See “Mapping fonts between platforms for field cast members” on page 284.

Increasing or decreasing your view of the Stage

You can author in Director on a zoomed Stage—one that is either larger or smaller than the normal size of the movie. Additionally, the Stage includes an offstage canvas area within the Stage window but outside of the active movie area. This canvas area is useful for assembling your media either before or after they appear on the Stage.

The offstage canvas is also useful as a way to preload media in projectors. For example, sprites in a frame, but offstage, are loaded into memory so they are ready to play in the subsequent frame.

28 Chapter 1

When you change the size of the Stage, any guides or grids you use to assist you with alignment will also scale to the zoomed size, and you can manipulate Stage objects in the same way that you would on a Stage that is not zoomed.

To zoom the Stage, do one of the following:

Press Control+the Plus (+) key (Windows) or Command+the Plus (+) key (Macintosh) to zoom in and increase the Stage size. Press Control+the Minus (-) key (Windows) or Command+the Minus (-) key (Macintosh) to zoom out and decrease the Stage size. (In Windows, if you want to use the keys on the numeric keypad, NumLock must be off.)

You can press the keys repeatedly until the Stage is the desired size.

Select a zoom amount from the Zoom menu in the lower left corner of the Stage.

Zoom menu

Note: If you don’t see the Zoom menu, select Edit > Preferences > General, check Show Stage Scrollbars, and then click OK.

Select View > Zoom, and select Zoom Stage In to increase the size of the Stage in increments, Zoom Stage Out to decrease Stage size, or a percentage to select a specific Stage size.

To zoom in while selecting an area of the Stage to center within the zoomed window, select the Magnifying Glass tool from the Tool palette. Click a point on the Stage to zoom and center.

To zoom out while selecting an area of the Stage to center within the zoomed window, select the Magnifying Glass tool from the Tool palette. Press Alt (Windows) or Option (Macintosh) while clicking a point on the Stage to zoom and center.

The Stage’s title bar indicates the zoom Stage size expressed as a percentage of the normal Stage size.

About Sprites

A sprite is an object that controls when, where, and how cast members appear in a movie. You create sprites by placing cast members on the Stage or in the Score. Creating a Director movie consists largely of defining sprites’ properties, where they appear, when they appear in the movie, and how they behave. Different sprites can be created from a single cast member. Each sprite can have its own values for different properties, and most changes to these properties do not affect the cast member. Most changes to a cast member, however, will change the sprites created from that cast member.

For information on creating and changing sprites, see “Creating sprites” on page 157.

Director Basics 29

About channels in the Score

Channels are the rows in the Score that control your media. The Score contains sprite channels and special effects channels.

Sprite channels are numbered and contain sprites that control all visible media in the movie. Effects channels at the top of the Score contain behaviors as well as controls for the tempo, palettes, transitions, and sounds. The Score displays channels in the order shown in the following figure.

Markers channel

Tempo channel

Palette channel

Transition channel

Sound channels

Behavior channel

Sprite channels

The first channel in the Score contains markers that identify places in the Score, such as the beginning of a new scene. Markers are useful for making quick jumps to specific locations in a movie. See “Using markers” on page 42.

Although the Score can include as many as 1000 channels, most movies use as few channels as possible to improve performance in the authoring environment and during playback. Sprites in higher channels appear on the Stage in front of sprites in lower channels. Use the Property inspector’s Movie tab to control the number of channels in the Score for the current movie. See “Setting Stage and movie properties” on page 27.

Turning channels on and off

To hide the contents of any channel on the Stage, or to disable the contents if they are not visible sprites, you use the button to the left of the channel. When you turn off a special effects channel, the channel’s data has no effect on the movie. You should turn off Score channels when testing performance or working on complex overlapping animations. Turning off a channel has no effect on projectors or Shockwave.

30 Chapter 1

Loading...
+ 594 hidden pages