xxxxxxxxxx
35
let n;
function setup() {
createCanvas(400, 400);
n = new Nucleus(200,200,1);
}
function draw() {
background(220);
n.show();
}
class Nucleus {
constructor(x,y,r) {
this.r = r;
this.x = x;
this.y = y;
this.seed= random(10);
}
show() {
push();
translate(this.x, this.y);
noiseSeed(this.seed);
for (let i=0;i<360;i++) {
push();
rotate(i);
translate(50+30*noise(i/5000),0);
point(0,0);
pop();
}
pop();
}
}