sketch
var r= 230;
var g= 250;
var b= 250;
function setup() {
createCanvas(600, 600);
//background(r, g, b);
}
function draw() {
background(r, g, b,20);
angleMode(DEGREES);
//hours
push();
rectMode(CENTER);
var h = hour();
translate(width/2,height/2);
rotate(h*30-180);
noFill();
rect(0,0,400,400);
rect(0,0,1,500);
pop();
//seconds
push();
var s = second();
translate(width/2,height/2);
rotate(s*6-135);
fill(63, 12, 12);
noStroke();
ellipse(150,150,40,40);
ellipse(-150,-150,20,20);
pop();
//minutes
push();
var m = minute();
translate(width/2,height/2);
rotate(m*6-180);
head(0,0);
pop();
}
function head(x,y){
//head
noStroke();
fill(255, 235, 117);
ellipse(0,0,300,300);
//eyes
strokeWeight(1);
fill(255);
ellipse(-70,0,80,15);
ellipse(70,0,80,15);
noStroke();
fill(38, 20, 0);
ellipse(-70,0,15,15);
ellipse(70,0,15,15);
//ears
fill(255, 235, 117);
ellipse(-150,0,30,50);
ellipse(150,0,30,50);
ellipse(-150,20,50,60);
ellipse(150,20,50,60);
//studs
fill(0, 48, 46);
ellipse(-160,30,10,10);
ellipse(160,30,10,10);
//mouth
fill(145, 36, 36);
arc(0,40,30,30,0,180);
//dots
for(var x = 0; x<3; x++){
for(var y = 0; y<3; y++){
var x2 = -40 + x * 40;
var y2 = -110 + y * 40;
fill(255, 250, 147);
ellipse(x2,y2,20,20);
}
}
}