the classic playground game of stoplight.

you are only visible when moving. 

get to the blue area, avoiding the spotlights, and only moving when the light is green or yellow.

how fast can you be?

submission to #TweetTweetJam 2018

code:

q=64z=circfill
camera(-q,0)c={8,10,11}o={2,4,3}::r::s=1x=rnd(64)-32y=120t=0
e=time()cls()for i=1,10 do
z(rnd(127)-q,rnd(q)+32,5,9)end::l::
t+=1
if t>20 and rnd(1)>.95then
t=0
if(s==1)s=3 else s-=1
end
v=pget(x,y)
if(v==9)goto d
if(v==1)goto w
rectfill(-q,0,q,32,1)
for i=1,3 do
z(0,i*8,4,o[i])end
z(0,s*8,4,c[s])
?flr(time()-e),-q,0,7
?"웃",x,y,0
if btn()!=0 then
if(btn(⬆️))y-=1
if(btn(⬅️))x-=1
if(btn(➡️))x+=1
?"웃",x,y,7
if(s==1)goto d
end
flip()goto l::d::
?"caught!\n  ❎",-15,q,8
if(btn(❎))goto r
goto d::w::
?"win!\n ❎",-6,q,11
if(btn(❎))goto r
goto w

Comments

Log in with itch.io to leave a comment.

(+1)

Another playground classic. I feel like this gameplay would translate well to online play.