So, Castlevania: Symphony of the Night is one of my favourite games of all time, and it’s also generally considered to be one of the best games ever made. And, as with all games, people ‘speedrun’ this game, which means trying to beat the game as fast as is humanly possible. There are several categories, each with certain rules and things that are and are not allowed.
This particular speedrun of Symphony Of The Night by Cosmo takes this concept to a whole new level. The end time of 7 minutes and 52 seconds is mind-blowing enough, but how he actually gets there is just utterly insane. Basically, he procures a very specific set of items in his inventory, and then proceeds to manipulate the items in his inventory in a extremely specific way, within very specific fractions of seconds of game-time, to use the sorting mechanism of the inventory to manipulate the assembly code in memory to make the game finish itself. All this, on the actual console itself, without tools, without additional software, without emulators, without anything.
The actual science or coding behind this technique was discovered and developed by a person named Sockfolder, and he put up a 40-minute stream to explain in detail what’s going on, with the contents of memory on the side of the screen so you can see exactly what’s happening. It’s mesmerising (even though I don’t fully understand what’s going on).
While the actual coding part of it can be discovered and explored in relative comfort of an emulator and other tools, actually pulling this off ‘live’, with just the tools at the disposal of any regular player, is absolutely amazing. This kind of stuff sits at the very fringes of programming, and I find it incredibly impressive.
In speedrunning this is known as Arbitrary Code Execution. It’s somewhat common on 8-bit titles because of the easy mapping of game variables to 8-bit assembly opcodes (only 0-255 to deal with), but doing arbitrary code execution on a 32-bit machine? That’s bonkers!
Here’s a video of Super Mario Bros. being created within Super Mario World! https://youtu.be/YHyaTCuZRzM?t=3m53s