flash on 2011-6-2
/**
* Copyright toshi.nojima ( http://wonderfl.net/user/toshi.nojima )
* MIT License ( http://www.opensource.org/licenses/mit-license.php )
* Downloaded from: http://wonderfl.net/c/urVR
*/
package {
import flash.display.*;
import flash.text.*;
import caurina.transitions.Tweener;
[ SWF( frameRate=30, backgroundColor=0x000000 ) ]
public class FlashTest extends Sprite {
public function FlashTest() {
var stg:Stage = this.stage;
for( var i:int = 0; i < 100; i++ ) {
var sp:Sprite = new Sprite();
var G:Graphics = sp.graphics;
var color:Number = Math.random() * 0xFFFFFF;
G.lineStyle( 1, color, 0.6 );
G.beginFill( color, 1 );
G.drawCircle( 0, 0, 3 );
G.endFill();
var pos1:Number = Math.random() * stg.stageWidth;
var pos2:Number = Math.random() * stg.stageWidth;
sp.x = pos1;
sp.y = stg.stageHeight / 2;
sp.alpha = 1;
this.addChild( sp );
Tweener.addTween( sp, { x:pos2, time:6, alpha:0, transition:"easeOutExpo" } );
}
}
}
}