Skip to content

Commit ff03172

Browse files
committed
Tests
1 parent cec152d commit ff03172

6 files changed

Lines changed: 10257 additions & 76 deletions

File tree

Wordle/FechuCArt.pde

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
int r;
2+
int g;
3+
int b;
4+
int x=(int)random(500);
5+
int y=(int)random(500);
6+
boolean paused=false;
7+
8+
void setup() {
9+
size(500, 500);
10+
background(255);
11+
r = (int)random(256);
12+
g = (int)random(256);
13+
b = (int)random(256);
14+
noStroke();
15+
}
16+
17+
void draw() {
18+
if (paused==false) {
19+
20+
x+=(int)random(-5, 5);
21+
y+=(int)random(-5, 5);
22+
r+=(int)random(-2, 2);
23+
g+=(int)random(-2, 2);
24+
b+=(int)random(-2, 2);
25+
26+
if (x>500 || x<0 || y>500 || y<0) {
27+
x=(int)random(500);
28+
y=(int)random(500);
29+
}
30+
31+
fill(r, g, b);
32+
ellipse(x, y, 5, 5);
33+
}
34+
}
35+
36+
void keyPressed() {
37+
if (key==' ') {
38+
paused=!paused;
39+
}
40+
}

Wordle/Wordle.html

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<!DOCTYPE html>
2+
<html>
3+
<head>
4+
<meta charset="utf-8" />
5+
<meta name="viewport" content="width=device-width" />
6+
<title>Wordle</title>
7+
<script type="text/javascript" src="processing.js"></script>
8+
</head>
9+
<body>
10+
<canvas data-processing-sources="FechuCArt.pde"></canvas>
11+
</body>
12+
</html>

0 commit comments

Comments
 (0)