Skip to main content

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

1k Game of LifeView game page

(Note: Not recommanded to those sensitive to flashing lights) Conway's Game of Life in Under 400 characters!
Submitted by silicon14 — 11 days, 14 hours before the deadline
Add to collection

Play Simulation

1k Game of Life's itch.io page

Characters/Bytes used
358

Source Code
g={}for y=0,128 do g[y]={} for x=0,128 do if((flr(rnd(2))+1)==1)g[y][x]=true else g[y][x]=false end end
::★::cls()ng={} for y=0,128 do ng[y]={} for x=0,128 do nc=0 for dy=-1,1 do for dx=-1,1 do if not (dy==0and dx==0)and g[y+dy]and g[y+dy][x+dx] then nc+=1 end end end
ng[y][x]=nc==3or(g[y][x]and nc==2) if(g[y][x])pset(x,y,7) end end
g=ng flip() goto ★

Leave a comment

Log in with itch.io to leave a comment.

Comments

HostSubmitted(+1)

Nice one
(...and only used about a quarter of the budget!)

Developer

Thanks! I think the uncompressed code is about 700 to 800 chars and I decided to compress it even further.

Submitted(+1)

I'm a simple man, I see Conway's game of life, I like.