package { import flash.display.*; import flash.events.*; import mx.core.UIComponent; public class Ratas extends UIComponent { public var sisu:Sprite = new Sprite(); public var kiiri:Number=10; public var ketta_r:Number=20; public var kiirte_r:Number=70; public var rot:Number=1; public function Ratas():void{ addChild(sisu); joonista(); } public function set kiired(uusarv:Number):void{ kiiri=uusarv; joonista(); } public function set rotspeed(uusarv:Number):void{ rot=uusarv; //removeChild(sisu); //joonista(); } private function joonista():void { var g:Graphics=sisu.graphics; g.clear(); g.lineStyle(15,0x000000); g.beginFill(0xffffff, 80); g.drawCircle(0,0,kiirte_r); g.lineStyle(4,0x000000); g.beginFill(0x000000, 80); g.drawCircle(0,0,ketta_r); for(var i:Number=0; i