Skip to content

Commit c344a89

Browse files
authored
Merge pull request #2 from sqdorte/master
jooj
2 parents 7d31cd8 + 09a7d6c commit c344a89

File tree

2 files changed

+42
-12
lines changed

2 files changed

+42
-12
lines changed

index.html

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,13 @@
11
<!DOCTYPE html>
2-
<html>
3-
<head>
4-
<meta charset="UTF-8">
5-
<style>
6-
body {
7-
margin: 0;
8-
}
9-
</style>
10-
</head>
11-
<body>
12-
<iframe style="position:fixed; top:0px; left:0px; bottom:0px; right:0px; width:100%; height:100%; border:none; margin:0; padding:0;" src="https://www.koalastothemax.com/?aHR0cHM6Ly9pLmltZ3VyLmNvbS94MXlFQUVoLnBuZw=="></iframe>
13-
</body>
2+
<html lang="">
3+
<head>
4+
<meta charset="utf-8">
5+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
6+
<title>jooj</title>
7+
<style> body {padding: 0; margin: 0;} </style>
8+
<script src="https://cdnjs.cloudflare.com/ajax/libs/p5.js/0.7.3/p5.min.js"></script>
9+
<script src="jooj.js"></script>
10+
</head>
11+
<body>
12+
</body>
1413
</html>

jooj.js

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
function setup() {
2+
createCanvas(screen.width, screen.height);
3+
background(255);
4+
}
5+
6+
var a = 0;
7+
var r = 50;
8+
var m = Math.floor(Math.random()*800 + 250)
9+
var i = -1;
10+
11+
function draw() {
12+
if (i <= m+1) {
13+
var x = r * cos(a);
14+
var y = r * sin(a);
15+
16+
a += 0.1;
17+
r += 0.3;
18+
i += 1;
19+
20+
if (i == 0 || i == m+2) {
21+
char = "j"
22+
} else {
23+
char = "o"
24+
}
25+
26+
push();
27+
translate(width / 2, height / 2);
28+
text(char, x,y)
29+
pop();
30+
}
31+
}

0 commit comments

Comments
 (0)