flash on 2011-7-17

by bradsedito
♥0 | Line 23 | Modified 2011-07-17 05:56:24 | MIT License
play

ActionScript3 source code

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






package 
{
    import flash.display.Sprite;
    import flash.events.*;
    
    public class SimpleSpriteRotation extends Sprite 
    {
        public function SimpleSpriteRotation() 
        {
            var shape:Sprite = new Sprite();
            
            addEventListener(Event.ENTER_FRAME, loop);
            shape.graphics.beginFill( 0x131413 );
            shape.graphics.drawCircle( 0, 25, 50);
            shape.graphics.endFill();
            shape.x = stage.stageWidth  /2;
            shape.y = stage.stageHeight /2;
            addChild(shape);
            
            function loop(event:Event):void
            {
//              shape.rotationZ += ( Math.cos(45*Math.PI/180) )*15;     
                shape
            }       
        }
    }
}