Setting the width and height of a pure-ActionScript application

Squished together from the post and a comment, when making a pure-AS application using Eclipse/Flex 2/3, you can control the width, height, initial framerate and background color using metadata tags. Metadata tags are used by the compiler, but not the swf. In other words, it tells the compiler to do something when it’s putting everything together, and are special instructions it only needs to do the one time.

Tomorrow I being my first pure-AS project! Writing an entire game in code and not technically using Flash CS3, other then dealing with art! Wish me luck!

package
{
[SWF(width="300", height="200", frameRate="18", backgroundColor="#FFFFFF")]
public class MyApp extends Sprite
{

}
}

Cool. Aaron and I were trying to find how to do this at quittin’ time today, I dug it up with the magic of the google.

mikemo ยป Setting the width and height of a pure-ActionScript application

Leave a Comment