Skip to content

Instantly share code, notes, and snippets.

@netdesign
Created December 10, 2011 23:51
Show Gist options
  • Save netdesign/1457141 to your computer and use it in GitHub Desktop.
Save netdesign/1457141 to your computer and use it in GitHub Desktop.
Movimento
// La posizione del punto viene dichiarata con due variabili x ed y
int x = 320;
int y = 180;
float move = 0.0;
void setup(){
size(640, 360);
smooth();
}
void draw(){
background(0);
move = move + 0.5;
stroke(255);
strokeWeight(12);
point(x+(move/3), y+move);
point(x*0.6+move, y*1.1-move);
point(x*1.5-move, y+140+move);
point(x*1.2+(move/2), y-90-(move/2));
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment