week two dra­w­i­n­g with code

by sherly chen
  • Show Sketch
/** @peep sketchcode */
int x=0; 
void setup() {
  size(400,400);
}
 
void draw(){
background(90,30,50);
stroke(100,30,150);
strokeWeight(5);
line(100,100,300,100);
strokeWeight(5);
line(300,100,300,300);
strokeWeight(5);
line(100,300,300,300);
strokeWeight(5);
line(100,100,100,300);
line(100,100,300,300);
line(100,300,300,100);
fill(80,120,90);
ellipse(80+x,80,70,70);
ellipse(320-x,320,70,70);
if (++x > 400) {x=0;} 
}

Comments

Nobody has said anything yet.