-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmenu.js
37 lines (34 loc) · 985 Bytes
/
menu.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
module = new CorruptionModule()
module.init('canvas-container')
if (window.innerWidth > window.innerHeight)
module.start(window.innerWidth / 4, window.innerHeight / 2)
else
module.start(window.innerWidth / 2, window.innerHeight / 2)
setInterval(module.reset.bind(module), 20000)
window.onload = function () {
let limit = 1
let speed = 8
for (let i = 0; i < limit; i++) {
module.playOneFrame()
}
for (let i = 0; i < speed; i++) {
module.update()
}
}
module.update()
function openUrl(url) {
if (window.event.ctrlKey) {
window.open(url, '_blank')
} else {
location.href = url
}
}
var repeater = false
var dotSpan = document.getElementById("dotSpan")
setInterval(function () {
if (repeater === true && dotSpan.innerText.length < 40) {
dotSpan.innerText += " ."
} else if (dotSpan.innerText.length > "Dot: . . .".length) {
dotSpan.innerText =dotSpan.innerText.slice(0, -2)
}
}, 100)