lil' pico-8 projeccts
1pico-8 cartridge // http://www.pico-8.com
2version 41
3__lua__
4local d = 0.01
5local angle = 0.25
6
7local spin = true
8
9local ox = 64
10local oy = 64
11
12function _update()
13
14 if btnp(4) then
15 spin = not spin
16 end
17
18 if spin then
19 angle = (angle + d)%1
20 end
21end
22
23function _draw()
24 cls()
25 color(7)
26
27 local x = 64+cos(angle)*30
28 local y = 64+sin(angle)*30
29
30 print("angle: "..angle,10,0)
31 print("x: "..x,10,8)
32 print("y: "..y,10,16)
33
34 circ(64,64,30)
35
36 line(64,30,64,98)
37 line(30,64,98,64)
38
39 line(ox,oy,x,y,9)
40 line(x,oy,x,y,8)
41 line(ox,oy,x,oy,11)
42end
43__gfx__
4400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
4500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
4600700700000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
4700077000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
4800077000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
4900700700000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000