xxxxxxxxxx
126
let redColor, blueColor, greenColor;
let redColor2, blueColor2, greenColor2;
let redBg, blueBg, greenBg;
let redTongue, blueTongue, greenTongue;
function setup() {
createCanvas(400, 400);
angleMode(DEGREES);
}
function draw() {
background(redBg, blueBg, greenBg);
//Maximum Cat
let f=400;
//CAT
fill(redColor, greenColor, blueColor);
//EARS
triangle(30, 20, 50, 200, 150, 90);
push();
noStroke();
fill(100);
blendMode(SCREEN);
scale(0.75);
translate(30, 35);
triangle(30, 20, 50, 200, 150, 90);
pop();
triangle(f-30, 20, f-50, 200, f-150, 90);
push();
noStroke();
fill(100);
blendMode(SCREEN);
scale(0.75);
translate(100, 35);
triangle(f-30, 20, f-50, 200, f-150, 90);
pop();
//Face Cirlce
circle(200, 210, 300);
let y= 60
let x= 10
push();
push();
pop();
//WHISKERS
push()
noFill()
//bezier(anchorx1, anchory1, x2, y2, x3, y3, anchorx4, anchory4)
//bezier(170, 250, 100, 400, 90, 400, 150, 240);
strokeWeight(4);
//LEFT WHISKERS
line(170, 250, 70, 230);
line(170, 260, 73, 260);
line(170, 270, 90, 290);
//RIGHT WHISKERS
line(f-170, 250, f-70, 230);
line(f-170, 260, f-73, 260);
line(f-170, 270, f-90, 290);
pop()
//MOUTH
//arc(x, y, w, h, start, stop, [mode], [detail])
push()
angleMode(RADIANS);
fill(redTongue, greenTongue, blueTongue);
rect(190, 260, 30, 30, 60);
fill(redColor, greenColor, blueColor);
arc(200-20, 255, 40, 40, TWO_PI, PI);
arc(200+20, 255, 40, 40, TWO_PI, PI);
pop()
//circle(200, 260, 55);
pop()
//EYE
push()
fill(redColor2, greenColor2, blueColor2);
circle(200-y, 210, 55);
circle(200+y, 210, 55);
pop()
//EYE PUPIL
push();
fill(0);
ellipse(200-y, 210, 15, 55-10);
ellipse(200+y, 210, 15, 55-10);
pop()
//EYE SHINES
push();
noStroke();
fill(redColor+200, greenColor+200, blueColor+200);
circle(200+y-x, 210-x, 15);
circle(200-y-x, 210-x, 15);
pop();
//nose
push();
fill(0);
triangle(200-15, 240, 200+15, 240, 200, 255);
pop();
}
//RANDOM COLOR FUNCTIONS
//RAPID CLICK FOR A TRIP
function mousePressed() {
redColor = random(255);
greenColor = random(255);
blueColor = random(255);
redColor2 = random(70,255);
greenColor2 = random(70,255);
blueColor2 = random(70,255);
redBg = random(255);
greenBg = random(255);
blueBg = random(255);
redTongue = random(235,255);
greenTongue = random(155,200);
blueTongue = random(200,255);
}