var draw = function(){ if(mouseY < 150){ background(255,0,0); ellipse(100,100,100,100); } else if(mouseY < 250){ background(0,0,255); rect(200,200,200,200); } else{ background(0,255,0); arc(200,190,300,200,180,200); } else if(mouseY > 250) { background(255, 255, 0); fill(0); triangle(303, 32, 290, 88, 370, 109); } };