Guest User

Untitled

a guest
Jul 18th, 2018
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.52 KB | None | 0 0
  1. void setup(){
  2. size(500,450);
  3. smooth();
  4. frameRate(4);
  5.  
  6. }
  7.  
  8. //random on both sides
  9.  
  10. void draw(){
  11. background(150);
  12.  
  13. float [] randomArray = new float [12];
  14. for(int i=0; i<12; i++)
  15. randomArray[i]=random(height);
  16. }
  17.  
  18.  
  19. int x1=200;
  20. int x2=300;
  21.  
  22. /*for(int i=0; i<10; i++){
  23. line(x1, 0, x1, height);
  24. line(x2, 0, x2, height);
  25. line(x1, random(height), x2, random(height));
  26.  
  27. */
  28. for(int i=1; i<10; i++){for(int j=1; j<11; j++){
  29. line(x1,randomArray[i],x2,randomArray[j]);
  30. }
  31.  
  32. }
  33. }
Add Comment
Please, Sign In to add comment