18 comments

[ 1.8 ms ] story [ 52.6 ms ] thread
This is very interesting. Unfortunately it seems to be closed source and they're still working on a more technical blog post.

I wonder how they encode all the information in the PNG file? Apart from the .zip with the entire ROM I assume they snapshot the current memory state on the beginning of the Quote and all the subsequent inputs.

Most gameboy games use banked memory, swapped in as 16k chunks. I'd wager a guess that the recording process monitors what chunks get banked in during the recorded gameplay, removes any bank that isn't used, and then restarts the demo if that removed data is accessed, as a failsafe.

The Raccoon demo behaves the way I might expect this to work: most potential player inputs allow you to reach the Raccoon, trigger his two text prompts, and cut the grass with Link's sword. But you can't enter any other screen, can't leave the second screen out the bottom, and can't perform most other actions; the moment you do, the game would need to run code that the quote never accessed, which triggers the failsafe. Even performing certain "safe" actions out of order occasionally fails, I'm guessing due to the RNG for stuff like leaf particles and whatnot.

We actually monitor each individual byte of memory accessed, then add some (configurable) padding around those bytes to make the quotes more durable.

You can see what that looks like in this visualization of the Racoon demo: https://tenmile.quote.games/quote-visualizer.html#drop=https...

That's extremely cool, thanks a bunch for the clarification! I'm working on an NES emulator that runs in the browser, and while it's not fit for purpose yet (lacks save states and recorded-input playback), this might just inspire those features. Seems like it should be a fun weekend project :)
Awesome! I'm really happy to hear that. I expect that you're going to have a LOT of fun with that project. Please let me know if you ever need another pair of eyes to help with your project, even if it doesn't involve adding support for Playable Quotes. As I recall, the Game Boy shares a lot of design features with the NES.

Oh, and regarding recorded input playback. That is something we haven't gotten working yet. Some of the details for that are in our blog post. The short version is that button presses can happen in the middle of a scan-line, which can make it really tricky to play back if the emulator wasn't designed with that in mind!

You can see the source here: https://glitch.com/~tenmile we haven't taken the time to figure out what precisely what the appropriate license should be, though it will probably need to be GPL since the emulator we use is GPL licensed.

That said, the basics of making a quote are so simple that it should be pretty easy to add Playable Quote capabilities to other emulators with a minimal amount of code.

A full writeup of how it works is here: https://joel.franusic.com/playable_quotes_for_game_boy

Thanks for reminding me that our site said the post wasn't ready yet, I've just updated it with the link to that blog post!

It doesn't sound like they include the entire ROM, only the parts necessary to play back the recording. If you "take control", the game may try to access parts of the ROM which are missing, which causes the quote to reset. This happens frequently with the Metroid II example - the Tetris one seems much more robust.
Exactly right! Part of a quote is a "ROM validity mask" which is checked on each memory access. When an "invalid" memory address is requested, we'll fire a callback which in this case just resets the game.

The durability of each quote depends on the actions taken while the quote was being made. In the quote of Metroid II, for example, many of the sprites were not recorded, so unless you do exactly what was done in the recording, you'll get a reset.

Here's a visualization of the Metroid II quote: https://tenmile.quote.games/quote-visualizer.html#drop=https...

Hi everyone, I’m one of the authors of this project and I’m happy to answer questions!

You can read more about how this works here: https://joel.franusic.com/playable_quotes_for_game_boy

We also have a presentation on Playable Quotes to the Internet Archive and the video of that presentation is here: https://archive.org/details/joel-franusic-presentation

I love this idea! I have a lot of little game memories that would fit perfectly into this form. I wonder how much of our feelings about particular moments are informed by the process of playing up to that point or what comes after. e.g. the introduction of the Medium Tank in Advance Wars is uninteresting on its own but really funny in retrospect when you get to the end of the game and you still have yet to see anything bigger (well i found it funny anyway).
Very interesting concept as well as technical execution by encoding the whole thing into the PNG pixels :)

Also cool to see myself featured there, so in case you need another homebrew game with access to the source try https://gitlab.com/BonsaiDen/vectroid.gb

Thanks for writing Tuff! It was the main game we used during testing.
Every time I visit this site, the images are broken.

Screenshot: https://i.imgur.com/LTevV36.png

With that out of the way, this is excellent and super impressive. I've always dreamed of a "video game magazine" which is a piece of software that lets you just play different interesting parts of retro games. Like these quotes bundled together with a bit of commentary to add structure.

I played Tetris without Tetris and got a Tetris, so somehow the filtering seems not foolproof :-)
I got a Tetris too but the quote restarted as soon as it happened. I think this might be what they meant by “without Tetris”. Based on the high level description of how this works, I bet the code for handling a Tetris is masked out and accessing it during play restarts the quote.
> I bet the code for handling a Tetris is masked out and accessing it during play restarts the quote

Yes! You're exactly right.