Guest User

Untitled

a guest
Jul 16th, 2018
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.48 KB | None | 0 0
  1. float r = 241;
  2. float g = 94;
  3. float b = 102;
  4.  
  5. void setup () {
  6. size (400,380);
  7. background(0);
  8. }
  9.  
  10.  
  11. void draw () {
  12. frameRate(17);
  13. strokeWeight(10);
  14. for (int i=-6; i<400; i=i+40) {
  15. line (0,i,400,i);
  16. stroke(0);
  17. }
  18. for (int a=mouseX; a<440; a=a+40) {
  19. line (a-40,0,a-40,400);
  20. stroke(a,r,g,b);
  21. }
  22.  
  23. }
  24.  
  25. void keyPressed () {
  26. r = random (255);
  27. g = random (255);
  28. b = random (255);
  29.  
  30. }
  31.  
  32. void mousePressed() {
  33. saveFrame();
  34. println("save a picture");
  35. }
Add Comment
Please, Sign In to add comment