Snake on
a Grid!
Guide a growing snake to eat food without hitting the walls or yourself. Learn grid-based movement, Lua tables and collision detection.
Guide a growing snake to eat food without hitting the walls or yourself. Learn grid-based movement, Lua tables and collision detection.
Each step adds one feature. Write the code, watch it come alive in the canvas, then make it your own.
Keep the PICO-8 cheatsheet + Pixel Studio open
Lua syntax for PICO-8 in one tab, draw 16ร16 sprites in the other - stay on-site while you build.
if btn(1) then player_x += speed endfunction _update()function _draw()if btn(0) then player_x -= speed endendcls(0)spr(1, player_x, player_y)endBuild it in the browser first
Try this project step by step right here: write the code, watch it run, then download it and keep building in your engine.