ZSNES Creator Explains How He Achieved ‘Rollback’ Netcode On Dial-Up Connections In 1997
Kworld Trend | ZSNES Creator Explains How He Achieved ‘Rollback’ Netcode On Dial-Up Connections In 1997 ,
If you were around in the late 90s and owned a PC, there’s a good chance you encountered ZSNES, one of the first retro emulators to really break into the mainstream.
Coded by zsKnight, the emulator was stunning for 1997: not only did it offer excellent performance, but it even allowed network gaming. Remember, this was back when most homes still had dial-up connections and the average PC was less powerful than a smart watch today.
Speaking to Zophar in one of his very first interviews (thanks, PC Gamer), zsKnight explains how he was able to create such an accurate emulator almost 30 years ago:
“When I was 16, I started learning assembly, and I was so fascinated by optimization, doing everything as fast as possible. I started coding everything in pure assembly – right down to the Windows port, there wasn’t a single line of C code. It’s optimized to the brim. When I started it, I wanted a Super Nintendo emulator that could play at full speed on my computer, but I actually didn’t expect to achieve that goal.”
One of the most impressive aspects of ZSNES was that it allowed online play in 1997 and even featured its own version of rollback netcode.
zsKnight explains how this magic was achieved:
“30 times per second I do a secret save state. The emulator goes forward, maybe 30 milliseconds, and every time it receives a packet that the controller has changed, it rewinds to that frame and replays the emulation up to the current point with that new input buffer.”
zsKnight is currently working on Retro 8-bit Endurance.