1 .TH as3compile "1" "April 2009" "as3compile" "swftools"
3 as3compile - Compile .as ActionScript 3.0 files to swf.
6 .B as3compile file.as [-o file.swf]
9 Compiles a file written in ActionScript 3.0 to a SWF file.
13 \fB\-h\fR, \fB\-\-help\fR
14 Print short help message and exit
16 \fB\-V\fR, \fB\-\-version\fR
17 Print version info and exit
19 \fB\-v\fR, \fB\-\-verbose\fR
22 \fB\-q\fR, \fB\-\-quiet\fR
25 \fB\-C\fR, \fB\-\-cgi\fR
26 Output to stdout (for use in CGI environments)
28 \fB\-R\fR, \fB\-\-resolve\fR
29 This flag will cause the compiler to try filenames like "FooBar.as" for classes named "FooBar".
31 \fB\-D\fR, \fB\-\-define\fR \fInamespace::variable\fR
32 Set a compile time variable (for doing conditional compilation)
34 \fB\-X\fR, \fB\-\-width\fR
37 \fB\-Y\fR, \fB\-\-height\fR
40 \fB\-r\fR, \fB\-\-rate\fR
41 Set target SWF framerate
43 \fB\-M\fR, \fB\-\-mainclass\fR
44 Set the name of the main class (extending flash.display.MovieClip)
46 \fB\-l\fR, \fB\-\-library\fR \fIfile\fR
47 Include library file \fIfile\fR. <file> can be an .abc or .swf file.
49 \fB\-I\fR, \fB\-\-include\fR \fIdir\fR
50 Add additional include dir \fIdir\fR.
52 \fB\-N\fR, \fB\-\-local-with-network\fR
53 Make output file "local with networking"
55 \fB\-L\fR, \fB\-\-local-with-filesystem\fR
56 Make output file "local with filesystem"
58 \fB\-T\fR, \fB\-\-flashversion\fR \fInum\fR
59 \fInum\fR must be >= 9.
61 \fB\-o\fR, \fB\-\-output\fR \fIfilename\fR
62 Set output file to \fIfilename\fR.
65 The following is a basic as3 file that can be compiled e.g.
66 with \fBas3compile -X 400 -Y 400 smiley.as\fR
71 import flash.display.MovieClip
73 public class Main extends MovieClip
77 this.graphics.beginFill(0xcccc00)
78 this.graphics.drawCircle(200,200,200)
79 this.graphics.endFill()
80 this.graphics.beginFill(0x000000)
81 this.graphics.drawCircle(140,150,50)
82 this.graphics.drawCircle(260,150,50)
83 this.graphics.drawRoundRect(140,270,120,10,20);
84 this.graphics.endFill()
91 Matthias Kramm <kramm@quiss.org>