12,297
edits
(Created page with "<syntaxhighlight lang="javaScript"> void setup(){ size(600,600); frameRate(100); } void draw(){ background(255); stroke(1); for(int i = 50; i < width; i = i...") |
No edit summary |
||
Line 3: | Line 3: | ||
void setup(){ | void setup(){ | ||
size(600,600); | size(600,600); | ||
} | } | ||
Line 11: | Line 10: | ||
for(int i = 50; i < width; i = i+50){ | for(int i = 50; i < width; i = i+50){ | ||
line(i,0,i,height); | line(i,0,i,height); | ||
line(width,i,0,i); | |||
} | |||
} | |||
</syntaxhighlight> | |||
Ein bisschen zappeliger: | |||
<syntaxhighlight lang="javaScript"> | |||
void setup(){ | |||
size(600,600); | |||
frameRate(100); | |||
} | |||
void draw(){ | |||
background(255); | |||
stroke(1); | |||
for(int v = 50; v < width; v = v+50){ | |||
line(v+random(-5,5)*(mouseX/15),0,v,height); | |||
} | } | ||
for(int | for(int h = 50; h < height; h = h+50){ | ||
line( | line(0,h+random(-5,5)*(mouseY/15),width,h); | ||
} | } | ||
} | } | ||
</syntaxhighlight> | </syntaxhighlight> |