void setup() {
size(800, 500);
background(255, 255, 255);
for (int i=1; i<=num; i++) {
hat (int(random(255)), int(random(255)), int(random(255)));
}
}
void hat(int R, int G, int B) {
fill(R, G, B);
rect(32, 3, 35, 20); //hat
rect(27, 14, 45, 5);
rect(32, 11, 35, 3); // hat band
fill(87); // charcoal
ellipse(50, 55, 70, 75); // body and wings
ellipse(19, 65, 12, 40);
ellipse(81, 65, 12, 40);
fill(0); // black
ellipse(48, 40, 2, 2); // eyes
ellipse(52, 40, 2, 2);
fill(250); // white
ellipse(50, 75, 30, 35); // tummy
fill(200, 150, 0); // orange
ellipse(39, 93, 15, 5); // feet
ellipse(61, 93, 15, 5);
triangle(44, 44, 56, 44, 50, 49); // beak
}
size(800, 500);
background(255, 255, 255);
for (int i=1; i<=num; i++) {
hat (int(random(255)), int(random(255)), int(random(255)));
}
}
void hat(int R, int G, int B) {
fill(R, G, B);
rect(32, 3, 35, 20); //hat
rect(27, 14, 45, 5);
rect(32, 11, 35, 3); // hat band
fill(87); // charcoal
ellipse(50, 55, 70, 75); // body and wings
ellipse(19, 65, 12, 40);
ellipse(81, 65, 12, 40);
fill(0); // black
ellipse(48, 40, 2, 2); // eyes
ellipse(52, 40, 2, 2);
fill(250); // white
ellipse(50, 75, 30, 35); // tummy
fill(200, 150, 0); // orange
ellipse(39, 93, 15, 5); // feet
ellipse(61, 93, 15, 5);
triangle(44, 44, 56, 44, 50, 49); // beak
}