alien1

 

 

 

 

 

 

alien2

 

 

 

 

 

alien3

 

 

 

 

 

alien4

 alien 3                                           terug naar de inleiding
 
De alien is samengesteld met de onderdelen: hoofd, armen en benen
 
 

size(960, 540); 
//fullScreen(); 
float x = width/2; 
float y = height/2; 
float nx = height/15; 
float ny = height/25; 
background(#E6FBFF); 
 
fill(#F78E0C,200); 
//omtrek hoofd 
beginShape(); 
{ 
  vertex(x-nx/2,   y);          //1 
  vertex(x-nx/2,   y-ny);       //2 
  vertex(x-2.5*nx, y-3*ny);     //3 
  vertex(x-3.5*nx, y-3*ny);     //4 
  vertex(x-3.5*nx, y-4*ny);     //5 
  vertex(x-2.5*nx, y-4*ny);     //6 
  vertex(x-nx/2,   y-6*ny);     //7 
  vertex(x+nx/2,   y-6*ny);     //8 
  vertex(x+2.5*nx, y-4*ny);     //9 
  vertex(x+3.5*nx, y-4*ny);     //10 
  vertex(x+3.5*nx, y-3*ny);     //11 
  vertex(x+2.5*nx, y-3*ny);     //12 
  vertex(x+nx/2,   y-ny);       //13 
  vertex(x+nx/2,   y);          //14   
  endShape(CLOSE); 
} 
 
//antennes 
fill(0,255,0); 
triangle(x-1.5*nx, y-5*ny, x-2.5*nx, y-5*ny, x-1.5*nx, y-6*ny); 
triangle(x+1.5*nx, y-5*ny, x+2.5*nx, y-5*ny, x+1.5*nx, y-6*ny); 
 
//ogen 
fill(0,0,255); 
ellipse(x-nx, y-4.5*ny, nx/2, ny); 
ellipse(x+nx, y-4.5*ny, nx/2, ny); 
 
fill(255,0,0,200); 
//neus 
triangle(x-nx/2, y-3.5*ny, x, y-5*ny, x+nx/2, y-3.5*ny); 
//mond 
arc(x, y-3*ny, 3*nx, ny, radians(0), radians(180)); 
 
fill(0,255,0,200); 
//armen 
beginShape(); 
{ 
  vertex(x-nx/2,   y+2*ny);   //1 
  vertex(x-nx/2,   y+ny);     //2 
  vertex(x-2.5*nx, y+3*ny);   //3 
  vertex(x-3.5*nx, y+2*ny);   //4 
  vertex(x-3.5*nx, y+ny);     //5 
  vertex(x-2.5*nx, y+2*ny);   //6 
  vertex(x-nx/2,   y);        //7 
  vertex(x+nx/2,   y);        //8 
  vertex(x+2.5*nx, y+2*ny);   //9 
  vertex(x+3.5*nx, y+ny);     //10 
  vertex(x+3.5*nx, y+2*ny);   //11 
  vertex(x+2.5*nx, y+3*ny);   //12 
  vertex(x+nx/2,   y+ny);     //13 
  vertex(x+nx/2,   y+2*ny);   //14 
  endShape(CLOSE); 
} 
 
//benen 
fill(255,146,13,200); 
beginShape(); 
{ 
  vertex(x-nx/2,   y+7*ny);     //1 
  vertex(x-2.5*nx, y+7*ny);     //2 
  vertex(x-2.5*nx, y+6.5*ny);   //3 
  vertex(x-1.5*nx, y+6.5*ny);   //4 
  vertex(x-1.5*nx, y+6*ny);     //5 
  vertex(x-2.5*nx, y+5*ny);     //6 
  vertex(x-1.5*nx, y+4*ny);     //7 
  vertex(x-1.5*nx, y+3*ny);     //8 
  vertex(x-nx/2,   y+2*ny);     //9 
  vertex(x+nx/2,   y+2*ny);     //10 
  vertex(x+1.5*nx, y+3*ny);     //11 
  vertex(x+1.5*nx, y+4*ny);     //12 
  vertex(x+2.5*nx, y+5*ny);     //13 
  vertex(x+1.5*nx, y+6*ny);     //14 
  vertex(x+1.5*nx, y+6.5*ny);   //15 
  vertex(x+2.5*nx, y+6.5*ny);   //16 
  vertex(x+2.5*nx, y+7*ny);     //17 
  vertex(x+nx/2,   y+7*ny);     //18 
  vertex(x+nx/2,   y+6*ny);     //19 
  vertex(x+1.5*nx, y+5*ny);     //20 
  vertex(x+nx/2,   y+4*ny);     //21 
  vertex(x-nx/2,   y+4*ny);     //22 
  vertex(x-1.5*nx, y+5*ny);     //23 
  vertex(x-nx/2,   y+6*ny);     //24 
  endShape(CLOSE); 
}