Game jam submission for Shenanijam (sticky justice) and Pizza Jam (memory). Made in Pico-8 in 36 hours. Submission page: https://tarngerine.itch.io/justice-pizza

You're a pizza who works for a delivery place. Remember customer's orders and collect the ingredients in the correct order!

- Press Z to shoot cheese to capture ingredients, then touch them to collect.
- Hold Z to reset a stage.

Was fun to bust this out much quicker than I have for my previous two jams, but I still hate rewriting collision detection/basic physics every project. Also had a hard time being inspired for music this time.

im doing this flag waving animation, and ive gotten it to work via pset but it drops to 15fps while animating. if i reduce the height of the flag to a certain point, it'll rise back to 30fps. any tips here on what i could do to improve?

note: i dont understand a lot of the memory/buffer methods that i've seen mentioned elsewhere, should i be looking at that? any examples?

You could optimize some of the flag by using vertical stripes with rectfill(), but even with pset(), you can run a lot faster by extracting a bunch of loop invariants.

I've rewritten this section of your code:

local c = 0 for y=0,48 do for x=0,127 do c = (y==0 or y==48) and 7 or (y==16) and 7 or (y>16 and y<48) and 3 or 8 if (not level.started and level.inittime>((x+y)/8+cos(y/4))) or (level.started and (level.inittime-level.starttime)<((x+y)/8+cos(y/4))) then pset(x,y+38+(sin((time()/2)+x/100)*1.1),c) end end end |

Into this, with comments to explain the basic ideas:

-- compute the vertical -- flag colors *once* -- (could go elsewhere) local p = {} for y=0,48 do p[y] = (y==0 or y==48 or y==16) and 7 or y>16 and 3 or 8 end -- extract x,y-loop invariants -- and choose two functions so -- we will wipe-on or wipe-off local t2 = time()/2 local l = level.inittime local lt_pset = function() end -- nop local gt_pset = pset if level.started then l -= level.starttime lt_pset,gt_pset = gt_pset,lt_pset -- swap draw/not-draw sides end -- use pico-8 "hardware" -- to effectively add 38 to -- all submitted y values camera(0,-38) for x=0,127 do -- y-loop invariant local s = sin(t2+x/100)*1.1 -- render a wipe-on or -- wipe-off depending on -- which way we set the -- two pset functions. for y=0,48 do if l<((x+y)/8+cos(y/4)) then lt_pset(x,y+s,p[y]) else gt_pset(x,y+s,p[y]) end end end -- reset camera offset camera() |

This easily runs 30, and at least in my little test, ran 60 for me.

As an aside, it's not as expanded as it appears with all of those explanatory comments. This is the brief version:

local p = {} for y=0,48 do p[y] = (y==0 or y==48 or y==16) and 7 or y>16 and 3 or 8 end local t2 = time()/2 local l = level.inittime local lt_pset = function() end local gt_pset = pset if level.started then l -= level.starttime lt_pset,gt_pset = gt_pset,lt_pset end camera(0,-38) for x=0,127 do local s = sin(t2+x/100)*1.1 for y=0,48 do if l<((x+y)/8+cos(y/4)) then lt_pset(x,y+s,p[y]) else gt_pset(x,y+s,p[y]) end end end camera() |

i know this was just a time-constrained jam game, but please please please can you make one of the two O/X buttons be jump? Up as jump is infeasible on a gamepad, which is the target fantasy input device for PICO-8, and also what the mobile web interface is. (lots of people forget to think about gamepads, but as a helpful guide when designing controls, remember: keyboard arrow buttons are controlled using multiple fingers, which is fundamentally different from a single thumb on a d-pad or joystick)

anyway I love pizza and pizza games and I applaud you for making this :) 👏🍕

[Please log in to post a comment]