pico-8 cartridge // http://www.pico-8.com
version 41
__lua__
function _init()
positionx=63
positiony=63
isnotclear=0
end
function _update()
--player movement--
if btn(➡️) then
positionx+=1
end
if btn(⬅️) then
positionx-=1
end
if btn(⬆️) then
positiony-=1
end
if btn(⬇️) then
positiony+=1
end
end
function _draw()
--basic level system
cls()
spr(1, positionx,positiony)
if isnotclear == 0 then
spr(1,positionx,positiony)
spr(2,12,12)
print("x:")
print(positionx)
print("y:")
print(positiony)
--collisions(can only be in draw)
if positionx == 12 then
if positiony == 12 then
print("on it")
cls()
spr(1,positionx,positiony)
isnotclear=1
end
end
end
end
__gfx__
00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
00700700000000000099000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
00077000005500000aa9a00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
0007700000ff000099aa900000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
0070070009999000a9aa900000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
00000000009900000999000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
00000000009900000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000