A new Paper Mario speedrun world record has been reached, and it's all thanks to The Legend of Zelda: Ocarina of Time. Don't worry, it will make sense in a minute.
Speedrunner JCog posted the new 54 minute and 22-second record video along with an explanation of what the hell is happening on Pastebin (opens in new tab). Here's the basic setup: speedrunners recently discovered a glitch that would let them overwrite parts of Paper Mario's game code as it ran, enabling what the community calls arbitrary code execution or ACE. Unfortunately, accessing that glitch with just a copy of Paper Mario and your controller requires impossibly precise inputs.
It turns out there's another way, thanks to a previously known Ocarina of Time glitch and the magic of the Nintendo 64 Expansion Pak. Here's the top-level explanation from JCOG:
"We're using ACE in OoT to write code to memory that we can reach with a glitch in Paper Mario after quickly swapping cartridges, and then that code lets us write more code with our filenames that warps us to the end of the game. It probably won't be allowed on the leaderboard (nor should it be), but it's pretty cool."
By messing around very carefully in Ocarina of Time, you can leave some instructions behind on the Expansion Pak's extra RAM (even though neither game is actually built to use it). Think of it like a key to the Paper Mario ACE glitch. Then if you turn off the console and immediately swap in Paper Mario, that key persists on the Expansion Pak, and you can use it to unlock the metaphorical door to the end of the game.
Regardless of whatever speedrunning categories it may or may not fall under, this is an incredible feat of understanding and manipulating games all on their own level.
See where Paper Mario (and Ocarina of Time) list of the best N64 games of all time.