packman_gura | Processing 1.2.1




Processing code : 

float x = 0;
float y = 300;
float z = 200;
float step = 2;
float step2 = 1.5;


void setup() {
  size(1000,500);
  //background(0);
}


void draw() {
  background(0);
  fill(255,255,0);
  ellipse(x, 250, 100, 100);
  smooth();


  fill(0);
  ellipse(x+15, 220, 20, 20);
  smooth();


  triangle(x, 250, x+80, y-50, x+80, z+50);
  smooth();


  x += step;
  y -= step2;
  z += step2;


  if (z > 250) {
    z = 200;
 } 
  if (y > 250) { 
    y = 300; 
 }   
  if  (x > 1050) {
    x = -50;
 }


 //saveFrame();
}


image sequence animated with VirtualDub 1.10.0 @45fps

1 comment: