Hypocycloidage

Alrite, this is like the first competition ive ever entered, so lets see how we go. Got the idea from a school project i did a while ago on hypocycloids. So yeah, see how we go. [AS]j = 0
col = [“0x5A70A3”,“0xA3AFCB”,“0x374562”,“0x315E68”,“0x146485”,“0x06222D”,“0x6BC4E9”,“0xF8A298”,“0xFBDC95”,“0xE8E0A8”,“0xDFD6B0”]
drawShape(random(10)+5)
function drawShape(a) {
b = a*(random(10)+4)
var shape = _root.createEmptyMovieClip(“shape”+j,j++)
shape._x = random(400)
shape._y = random(400)
i = 0
shape.lineStyle(random(2)+2, col[random(col.length)], 100);
shape.moveTo(b, 0);
shape.onEnterFrame = function() {
if (i<2*Math.PI) {
x = ((b-a)Math.cos(i))+(aMath.cos(((b/a)-1)*i));
y = ((b-a)Math.sin(i))-(aMath.sin(((b/a)-1)*i));
shape.lineTo(x, y);
i += Math.PI/90;
} else {
delete shape.onEnterFrame
drawShape(random(10)+5)
}
};
}[/AS]
Thats like less than 25 lines? does that matter, might put some other random things in tomorrow. How many lines is that actually counted as?

[EDIT]Seeing as imports are now not allowed my new version is kaput… :frowning:

Comments greatly appreciated. :smiley: