float posY, diam, posX;
void setup(){
size(1080,720);
diam = 100;
posY = 0-diam;
posX = width/2;
}
void draw(){
posY+=random(5);
posX+=random(4);
diam += 0.1;
// background(0);
ellipse(posX,posY,sin(diam)*100,sin(diam)*100);
if (posY>height){
posY=0;
}
if (posX>width){
posX= 0;
}
}
No comments:
Post a Comment