Log In  

Cart #pigeo-0 | 2021-09-19 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
2

My project for the Pico-1k jam.

Collect the green ball and avoid the red balls

--pigeo by yopenatal
cartdata("pigeo")function py(a,b,c)p(a,b+1,c,7)p(a,b,c,1)end
c=btn
r=rnd
p=print
s=circfill
x=68ll=0y=68t=0wa=0ma=0e=8+r(120)d=8+r(120)n=.1g={}z=0a=dget(0,a)st=0ti="pigeo"ef=0cx=ef
::b::flip()w=cos(ef/36)
if(ll>0)cls(7)ll-=1
if ll<=0then
ll=0cls(9)for kx=1,16 do for y=1,16do circ(kx*8-4,y*8-4,cx%36,14)end end if st==0then ef=(ef+1)%36cx=ef/2for i=1,3 do p(ti,53,48+w*5+w*i,7)end p(ti,53,48+w*5,1)py("made by yopenatal",32,118)py("press z to start",32,80)
if(btnp(4))st=1 g={}
end end
if st==1then
cx=z
x=(x+wa)%136y=(y+ma)%136ma+=n if(c(0))wa-=n
if(c(1))wa+=n
if(c(2))ma-=n*2t=(t+1)%2
if(c(3))ma+=n
if(x<e+9)and(x+9>e)and(y<d+9)and(y+9>d)then u={x=-flr(e/8)*8+128,y=-flr(d/8)*8+128}add(g,u)z+=1e=8+r(120)d=8+r(120) end
if(z>=a)a=z dset(0,a)
for o in all(g)do if(x<o.x+8)and(x+8>o.x)and(y<o.y+8)and(y+8>o.y)then x=68z=0y=68wa=0ma=0ll=15st=0end end for o in all(g)do circ(o.x-8,o.y-8,4,8)end s(x-8,y-8,4,13)s(e-8,d-8,4,11)end
py("score : "..z,1,10)py("hiscore : "..a,1,1)goto b
P#97554 2021-09-19 18:57

it's always crazy to me how people do this!

P#97902 2021-09-28 01:12

[Please log in to post a comment]

Follow Lexaloffle:        
Generated 2021-11-28 15:19:31 | 0.012s | Q:17