xxxxxxxxxx
var variable1=500;//Variable #1
var variable2=0;//Variable #2
function setup() {
createCanvas(815, 500);
background(0);
}
function draw() {
background(0,0,variable2);//background color
fill(300,300,100)//color of sun
ellipse(variable1,variable1,100,100);//sun
fill(variable1,variable1,0);
variable1=variable1-1;//makes the sun start at the bottom right and go to the top left
variable2=variable2+1//changes color of background to black and blue
stroke(0,0,0);//line color
strokeWeight(3);//weight of line
line(500,175,500,75);//lightening pole of tall building in the middle
fill(500,500,500,150);//color and clearness of cloud
noStroke();
ellipse(750,100,150,100);//cloud
fill(500,500,500,150);//color and clearness of cloud
ellipse(625,100,150,100);//cloud
fill(500,500,500,150);//color and clearness of cloud
ellipse(300,100,150,100);//cloud
fill(500,500,500,150);//color and clearness of cloud
ellipse(500,100,150,100);//cloud
fill(500,500,500,150);//color and clearness of cloud
ellipse(400,100,150,100);//cloud
fill(500,500,500,150);//color and clearness of cloud
ellipse(225,100,150,100);//cloud
fill(0,50,100);//color of tall building in the middle
rect(250,250,100,250);//tall building in the middle
fill(0,50,100);//color of building on the left of the tall building in the middle
rect(450,175,100,450);//building on the left of the tall building in the middle
fill(0,50,100);//color of small building on right of building in the middle
rect(600,400,100,400);//small building on right of building in the middle
fill(100,100,100);//color of building on the left
rect(50,300,75,500);//building of the left
fill(100,100,100);//color of building on the right
rect(750,175,50,400);//building on the right
fill(500,0,0);//color of middle of plane
ellipse(mouseX, mouseY,55,55);//middle of plane
triangle(mouseX,mouseY,mouseX-100,mouseY+50,mouseX+70,mouseY-80);//wing of plane
fill(0,0,0);//color of front of plane
ellipse(mouseX, mouseY,20,20);//front of plane
//Project by Luke Ehrenfreund
}