Skip to content

Instantly share code, notes, and snippets.

@gabrielflorit
Last active October 19, 2019 05:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gabrielflorit/b2142e88c9ddf8b771d5d260f4b5f4bf to your computer and use it in GitHub Desktop.
Save gabrielflorit/b2142e88c9ddf8b771d5d260f4b5f4bf to your computer and use it in GitHub Desktop.
SCRIPT-8
init = state => {
state.i = 0
state.elapsed = 0
}
update = (state, input, elapsed) => {
state.elapsed = elapsed
state.i = state.i + 1
if (state.i >= 60) {
state.i = 0
}
}
draw = state => {
camera()
clear(4)
print(1, 1, Math.ceil(state.elapsed), 0)
const alphabet = 'abcdefghijklmnopqrstuvwxyz'
range(100).forEach(i => {
print(random(0, 25), random(40, 123), alphabet, random(0, 7))
})
}
{
"iframeVersion": "0.1.255",
"lines": [
24,
0,
0,
0,
0,
0,
0,
0
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment