xxxxxxxxxx
function setup() {
createCanvas(windowWidth, windowHeight);
background(100);
}
function draw() {
for (y=10; y<height; y+=50)
{
for (x=10; x<width; x+=50)
{
noFill();
stroke(0, random(255), random(200));
ellipse(x, y, 20, 20);
}
}
if (mouseIsPressed) {
if (mouseButton == LEFT) {
frameRate(3);
}
}
if (mouseIsPressed) {
if (mouseButton == RIGHT) {
frameRate(100);
}
}
}