AS3 Metadata tags again

A small primer of some of the metadata tags of AS3 and their uses

Customising your SWF - using the metatags in the following manner will allow you set various parameters for the compiled swf
[SWF(backgroundColor="#FFFFFF", frameRate="31", width="550", height="400")]

Embedding image assets
[Embed(source="assets/images/background.jpg")]
protected var Background:Class;

[Embed(source="assets/images/background1.jpg")]
public var Background:Class;


Embedding Events for the Flex Framework for MXML compatibility
[Event(name="introStateLoaded", type="net.designstreet.DesignStreetEvent")]

0 comments:

My Instagram