3.17. Reusing Elements: Creating Symbols

Problem

You want to reuse an element in multiple places, use an element in a special capacity, such as a button, or simply optimize the use of timelines.

Solution

Convert the element to a graphic, button, or movie clip symbol.

Discussion

Architecture is one of the most important considerations in any Flash movie. Architecture refers to the structure and organization of a movie. You should always strive, in Flash, to keep different elements separate from one another. Yet Flash offers a number of different ways to accomplish this goal. You have seen layers and groups in this chapter. But a far more flexible and powerful solution is to use Flash symbols.

Flash symbols are reusable elements that have additional functionalities that vary by type of symbol. Symbols are reusable in that they are stored in a central repository in a movie, called the library. You can access the library by choosing Window → Library in any movie. When a library symbol is placed on the stage, it is called an instance. Instances are linked to symbols in-as-much as the symbols are the blueprints for the instances. If you change any part of a symbol, all its instances throughout the movie are updated instantly. An instance can vary from its parent symbol in the values assigned to instance properties, such as scaling, opacity, placement, and a handful of others. In addition, instances have unique identifiers, called instance names. One benefit of symbols’ reusability is that they ...

Get Flash 8 Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.