flash on 2014-9-29
♥0 |
Line 24 |
Modified 2014-10-07 17:42:53 |
MIT License
archived:2017-03-20 03:18:11
ActionScript3 source code
/**
* Copyright tepe ( http://wonderfl.net/user/tepe )
* MIT License ( http://www.opensource.org/licenses/mit-license.php )
* Downloaded from: http://wonderfl.net/c/39qY
*/
package {
import flash.display.*;
import flash.text.*;
import flash.events.*;
public class FlashTest extends Sprite {
private var s:Sprite = new Sprite();
private var r:Number=150;
public function FlashTest() {
// write as3 code here..
s.x= 200;
s.y =200;
addChild(s);
s.graphics.lineStyle(1,0x000000);
s.graphics.drawCircle(0,0,r);
for(var i:int=-9;i<10;i++){
var a:Number = i*10*Math.PI/180;
var y1:Number = Math.sin(a)*r;
s.graphics.lineStyle(1,0xff0000);
s.graphics.moveTo(-r,y1);
s.graphics.lineTo(r,y1);
s.graphics.drawCircle(Math.cos(a)*r,y1,3);
}
}
}
}