wonderburg7
11/25/2018 - 3:03 PM

lightning lines.pde

float ry = 0, ry2, i, j;

void setup() {
  size(700, 700);
  background(57);
  smooth();
  noFill();
  stroke(2);
  noLoop();
}
  
  void draw() {
    
  beginShape();

 for(j = 0; j < height; j++){  
  for(i = 0; i < height; i++){
  //curveVertex(ry, i);
  ry += int(random(-2,2));
  line(ry2, i, ry,i);
   ry2 = ry;
  }
     ry =+ j*2;
  }
  
  endShape();

}