xxxxxxxxxx
74
let letter=[ "i", "t", "c", "h"]
let d
let e
let c = 50
// function preload(){
// font= loadFont('Bodoni');
// }
function setup() {
// createCanvas(windowWidth, windowHeight);
createCanvas(windowWidth, windowHeight);
background(220);
textAlign(CENTER,CENTER)
// textSize(20)
angleMode(DEGREES)
}
function draw() {
ellipse(mouseX,mouseY, 4);
// fill(0);
noStroke()
textAlign(CENTER, CENTER); textSize(15);
text('"Itch not scratched"', windowWidth/2, 50);
//text
textAlign(CENTER, CENTER); textSize(10);
text('Hover', windowWidth/2, windowHeight-50);
// for{
// }
// c=255
// d=30
// e=30
a=random(-d,d)
b=random(-e,e)
background(220,220,220,22);
translate(windowWidth/2, windowHeight/2)
// fill(0,0,0,c)
textSize(20);
text (random(letter), a,b)
if ((mouseX > width/2-c) && (mouseX < width/2+c) &&
(mouseY > height/2-c) && (mouseY < height/2+c)) {
fill(0,0,0,60)
d=width/2
e=height/2
rotate=random(360)
} else {
fill('black')
d=20
e=20
}
}