flash on 2011-3-25

by John_Blackburne
you can import things that come with flash.
♥0 | Line 27 | Modified 2011-03-25 04:49:06 | MIT License
play

ActionScript3 source code

/**
 * Copyright John_Blackburne ( http://wonderfl.net/user/John_Blackburne )
 * MIT License ( http://www.opensource.org/licenses/mit-license.php )
 * Downloaded from: http://wonderfl.net/c/cpYp
 */

package  
{
	import flash.display.Sprite;
	import flash.display.BitmapData;
	import flash.display.Bitmap;
	import flash.events.Event;
       [SWF(width = "400", height = "400", frameRate = "60", backgroundColor = "#aaaaaa")]

	public class Contest extends Sprite 
	{
                var dat:BitmapData;
                
		public function Contest() 
		{
			addEventListener(Event.ADDED_TO_STAGE, init);
		}
		private function init(e:Event):void 
		{
			removeEventListener(Event.ADDED_TO_STAGE, init);
                        dat = new BitmapData(400, 400, false, 0x000000);
                        addChild(new Bitmap(dat));
			
			addEventListener(Event.ENTER_FRAME, update);
		}	
		private function update(e:Event):void 
		{
                        var fX:Number = root.mouseX, fY:Number = root.mouseY;
		}
	}
}