I'd really like to be able to advance the simulator one frame/update at a time to catch particular moments so I can debug them.
Maybe you can put everything in one function and call it via Simulator?
function playdate.keyReleased(key) updateGame() end
Not sure if that works, but might be worth a shot
The Simulator supports the Debugger Adapter Protocol, which means you should be able to breakpoint and step using the right companion tool.
I do it with Panic's own Nova editor. You may also be able to use VSCode Using breakpoints with LUA code - #13 by midouest
On the macOS simulator, you can step the simulator forward one frame while it's paused by holding the option key down and clicking the play button. I don't see any code implementing that function in the Windows/Linux simulator, though. I'll file it!
Very nice! Maybe a dedicated step button would be more discoverable?
I see that Option-Spacebar works too.
(But holding Option in the Playdate menu doesn't reveal that. Might be a useful little Mac-ism for the 7 people worldwide who like to hold Option to look for advanced menu commands.)
Love it! I'll be sure to make use of this.