xxxxxxxxxx
79
var x = 0;
var col1, col2, col3, col4, col5;
function setup() {
createCanvas(640, 225);
}
function draw() {
background(255);
emoji();
}
function star(p1, p2, p3, p4, p5, p6, p7,p8,p9,p10){
line(p1,p2);
line(p2,p3);
line(p3,p4);
line(p4,p5);
line(p5,p6);
line(p6,p7);
line(p7,p8);
line(p8,p9);
line(p9,p10);
line(p10,p1);
}
function emoji(){
col1 = color(255,255,0,x);
col2 = color(138, 90, 23,x);
col3 = color(255,255,255,x);
col4 = color(138, 90, 23,x);
col5 = color(255,0,0,x);
x = x+5;
noStroke();
ellipseMode(CENTER);
stroke(col2);
strokeWeight(2);
noFill();
ellipse(width/2,height/2,152,152);
noStroke();
fill(col1);
ellipse(width/2,height/2,150,150);
fill(col2);
ellipse(width/2 - 20,height/2 - 20,15,30);
ellipse(width/2 + 20,height/2 - 20,15,30);
arc(width/2,height/2 + 20, 80, 60, 0, PI, CHORD);
fill(col3);
arc(width/2,height/2 + 25, 70, 20, 0, PI, CHORD);
stroke(col2);
strokeWeight(2);
noFill();
ellipse(width/5,height/2,152,152);
noStroke();
fill(col1);
ellipse(width/5,height/2,150,150);
//ellipse(width/5 - 20,height/2 - 20,15,30);
//ellipse(width/5 + 20,height/2 - 20,15,30);
fill(col5);
ellipse(102, 87, 16);
ellipse(113.95, 87, 16);
ellipse(142, 87, 16);
ellipse(153.95, 87, 16);
triangle(width/5 + 20, height/2 - 5, width/5 + 5, height/2 - 25, width/5 + 35, height/2 - 25);
triangle(width/5 - 20, height/2 - 5, width/5 - 35, height/2 - 25, width/5 - 5, height/2 - 25);
fill(col2);
arc(width/5,height/2 + 20, 80, 60, 0, PI, CHORD);
fill(col3);
arc(width/5,height/2 + 25, 70, 20, 0, PI, CHORD);
}