xxxxxxxxxx
20
let yPos, hoehe;
function setup() {
createCanvas(300, 300);
yPos = height / 3;
hoehe = 100
}
function draw() {
background(255, 215, 0);
if (mouseY > yPos &&
mouseY < yPos + hoehe) {
fill(255, 0, 0);
} else {
fill(255);
}
rect(0, yPos, width, hoehe);
}