Skip to content

Instantly share code, notes, and snippets.

@jl
Created October 21, 2011 18:29
Show Gist options
  • Save jl/1304571 to your computer and use it in GitHub Desktop.
Save jl/1304571 to your computer and use it in GitHub Desktop.
Actionscript Hello World (no flex)
// Build: mxmlc MyApp.as
// Generates: MyApp.swf
// You can debug with browser debug player plugin,
// or using the debug player projector standalone app.
package {
import flash.display.Sprite;
import flash.events.Event;
public class MyApp extends Sprite {
public function MyApp() {
trace("Hello, world!");
addEventListener(Event.ADDED_TO_STAGE, onAddedToStage);
}
private function onAddedToStage(e:Event):void {
trace("Initialization that depends on stage.");
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment