Friday 26 August 2011

JS3 - Create A Sprite

Framework updated: not working on this older version.
Example:



Code:


        var sprite = new Sprite();
sprite.lineStyle(3,"0x00ff00");
sprite.beginFill("0x0000FF",0);
sprite.drawRect(10,10,100,100);
sprite.endFill();
addChild(sprite);

No comments:

Post a Comment