jueves, 28 de agosto de 2008

void setup (){
size(90,180);
background (0);
}
void draw (){
fill (255,255,0);
march ();
fill(0);
rect (30,90,10,20);
rect (10,110,20,10);
}
void march()
{
beginShape (POLYGON);
vertex (30,20);
vertex (40,20);
vertex (40,10);
vertex (60,10);
vertex (60,20);
vertex (70,20);
vertex (70,70);
vertex (60,70);
vertex (60,80);
vertex (70,80);
vertex (70,120);
vertex (60,120);
vertex (60,160);
vertex (70,160);
vertex (70,170);
vertex (50,170);
vertex (50,140);
vertex (40,140);
vertex (40,170);
vertex (20,170);
vertex (20,160);
vertex (30,160);
vertex (30,120);
vertex (10,120);
vertex (10,110);
vertex (20,110);
vertex (20,90);
vertex (30,90);
vertex (30,80);
vertex (40,80);
vertex (40,70);
vertex (30,70);
vertex (30,20);
endShape (CLOSE);
beginShape(POLYGON);
fill(0,255,0);
vertex (40,80);
vertex (60,80);
vertex (60,140);
vertex (30,140);
vertex (30,120);
vertex (40,120);
vertex (40,80);
endShape(CLOSE);
beginShape(POLYGON);
fill(0,0,255);
vertex (30,20);
vertex (40,20);
vertex (40,10);
vertex (60,10);
vertex (60,20);
vertex (70,20);
vertex (70,70);
vertex (60,70);
vertex (60,60);
vertex (40,60);
vertex (40,70);
vertex (30,70);
vertex (30,20);
endShape(CLOSE);
}

No hay comentarios: