Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines
A jam submission

Repeat the PatternView game page

How good is your memory? Can you repeat the pattern?
Submitted by voidgazerBon — 26 days, 6 hours before the deadline
Add to collection

Play game

Repeat the Pattern's itch.io page

Compressed Bytes used
896

Source Code (OPTIONAL)
function l(a,b,o)
w=o*(b-a)
if abs(w) < o*1.5 then
return b
else
return a+w
end
end
bgc=split"5,0,2,8"
bg={}
for i=1,100 do
add(bg,0)
end
function drcb()
for i=1,100 do
local b=bg[i]
if b>0 then
circ(i%10*12+10, flr(i/10)*12+10, 5, bgc[ceil(b)])
bg[i]-=0.03
end
end
if(rnd(10)>2)bg[flr(rnd(#bg))]=#bgc
end
function drc(a,c)
for i=0,35 do
if a[i+1] then
circ(i%6*12+x+7, flr(i/6)*12+34, 5, c)
end
end
end
function conc(a)
local b=""
for i=1,#a do
b..=tostr(a[i])
end
return(b)
end
lvl=1
bl=1
xt=27
x=-59
function _init()
cl=15
bl=max(bl,lvl)
a={}
pa={}
p=5
tm=160
tm2=200+min(lvl*10,120)
tm3=0
for i=1,36 do
add(a,false)
add(pa,false)
end
lvlm=lvl
if(lvl>35)lvlm=ceil(rnd(35))
for i=1,lvl do
a[flr(rnd(#a))+1]=true
end
end
function _draw()
if(tm3==0) x=l(x,xt,0.07)
cls(5)
drcb()
if(x==27)tm=max(0,tm-1)
p=mid(0,p,35)
rectfill(x,27,x+74,101,15)
if tm>0 or tm3>0 then
?tm,x,21
?"remember",x+44,21,15
drc(a,5)
if btnp(5) then
tm=0
end
else
?"repeat",x+51,21,9
?tm2,x,21
tm2=max(0,tm2-1)
if btnp(0) then
p-=1
end
if btnp(1) then
p+=1
end
if btnp(2) then
p-=6
end
if btnp(3) then
p+=6
end
if btnp(5) then
?"\aC"
pa[p+1]= not pa[p+1]
end
circ(p%6*12+x+7, flr(p/6)*12+34, 2, 9)
end
drc(pa, 9)
lvls=lvl
if(lvl<10)lvls=" "..lvl
?"level="..lvls.."\n===================",x,10,15
bls=bl
if(bl<10)bls=" "..bl
?"best="..bls,x+48,10,15
?"⬅️⬇️⬆️➡️ ❎",x,103
tm3=max(tm3-1,0)
if tm2 == 0 then
?"\aeeddc"
cl=-8
xt=-115
lvl=1
tm3=60
tm2=30
end
if conc(pa) == conc(a) then
?"\accddf"
xt=200
cl=-13
lvl+=1
tm3=20
tm2=60
a={}
end
if x>190 or x<-101 then
x=-100
xt=27
_init()
end
pal(8,-8,1)
pal(15,cl,1)
pal(5,-16,1)
pal(0,-14,1)
pal(9,-7,1)
end

Leave a comment

Log in with itch.io to leave a comment.

Comments

Submitted

That's gorgeous. Love the colors and effects. :)

Submitted(+1)

Very slick 1K game. It harder than you'd think too :)

HostSubmitted(+1)

This is a really polished entry.
Really nice UX, transitions and SFX throughout.
(Not to mention a themed animated bg also!)
Alas, the best I could manage was 5 - but my memory is awful, so that tracks! 😅
Great work, nice one 👍