Posted By

chrisaiv on 10/11/09


Tagged

as3


Versions (?)

Who likes this?

3 people have marked this snippet as a favorite

Demian
adrianparr
tspitzr


Flash: Adding Compiler Settings using AS3 Params


 / Published in: ActionScript 3
 

For those of us who dislike having to set Width, Height, Background Color, and Frame Rate in Stage Properties, here's an easy way to provide those Params in your Main ActionScript file.

  1. package
  2. {
  3. import flash.display.Sprite;
  4.  
  5. [SWF(width="448", height="445", backgroundColor="#000000", framerate="15")]
  6. public class Main extends Sprite
  7. {
  8. public function Main()
  9. {
  10. }
  11. }
  12. }

Report this snippet  

You need to login to post a comment.