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
| world.set(1980,1280)
display.color=color.hsb(197, 42, 92)
apple = display.emoji("🍎", random.pos())
repeat(50, () => {
display.rect(random.pos(), random.size(10, 50))
})
pl = display.emoji("🤩")
camera.follow(pl)
pl.collision((event) => {
if (!event.began) { return }
if (event.tag != "red_apple") { return }
event.other.goTo(random.pos())
})
input.up(() => {
pl.move(5)
})
input.left(() => {
pl.rotate(-5)
})
input.right(() => {
pl.rotate(5)
})
|