A fighting game fan has taken it upon themselves to improve Street Fighter 5's controversial netcode.
Redditor Altimor, who has created hitbox viewers for Guilty Gear Xrd and Dragon Ball FighterZ in the past, took just two days to address a bug that has plagued Street Fighter 5 online play since the game launched back in 2016.
According to Altimor, and indeed other prominent members of the fighting game community as well as developers of other fighting games, Street Fighter 5 includes a bug that can cause one players' game to lag behind the other's during online play. The upshot of this bug is one-sided "rollback" for one player, while the unaffected player remains oblivious.
Here's the science bit from Altimor:
"When the players' 'clocks' are synced, if there is e.g. a four frame packet round trip time between them, each player should be two frames ahead of the time of the last received input from their opponent, and experience two frame rollbacks.
"If one player lags behind, the other player will receive inputs from farther 'in the past' (up to 15 frames!) than they should, causing unnecessarily big rollbacks and artificial lag, while the player that's behind may even be receiving inputs that appear to be 'in the future' to their game and never experience rollbacks at all."
Altimor's fix ensures your "clock" never gets more than half of your packet round trip time ahead of your opponent's, so you never experience more rollback than them.
"This took a bit over two days to make, while Capcom hasn't patched the bug for four years," Altimor said. "Most of that was reverse engineering. It would take more like 30 minutes with the source code. MikeZ even made a tweet pinpointing the cause of the bug during the beta."
The MikeZ referenced here is Mike Zaimont of Skullgirls fame. MikeZ has discussed fighting game netcode at length in the past, and pinpointed the bug affecting Street Fighter 5 four years ago.
MikeZ also had a positive response to Altimor's fix, taking to Twitter to say "the source code provided looks legit" and, "I don't own the game, but it's PROBABLY worth trying if you're playing SFV CE on PC!"
Heyo, someone claims to have made a DLL replacement to fix the one-sided-rollbacks bug that SFV has had since it came out. (!!!)https://t.co/ywzxP9GPYl ?— Mike Zaimont (@MikeZSez) January 9, 2020
The sourcecode provided looks legit. I don't own the game, but it's PROBABLY worth trying if you're playing SFV CE on PC!
Early results appear to be positive - for those playing with the mod enabled on PC versus PC matches, that is:
I'll have a more in depth dive tomorrow, but here are some clips from a match I played tonight from my apartment in CALIFORNIA vs a player in SAUDI ARABIA using the new SFV PC netcode mod. Here are some highlights. It's so good. Sooo gooooood pic.twitter.com/NDSyT7QAdn— Just UltraDavid (@ultradavid) January 9, 2020
Ran a set with @Keoma89 before and after the netcode patch (he had his correctly installed from the beginning; mine was incorrectly installed at first, then patched correctly in the next clip)— Arlieth@CalradicButterlord (@Arlieth) January 9, 2020
It got a LOT more playable... for a 3-bar connection lol pic.twitter.com/KSSH6OHz4u
Thoughts after playing with @DanielRGT_— ? (@nothingxs) January 9, 2020
- It's surprising to me that this little fix made this much of a difference
- The game briefly jitters occasionally when there seems to be packet loss, as you'd expect from regular rollback
- The game was resistant to alt-tabbing
It's a different story once you take the mod online for crossplay, though. Tests are showing a PC with the fix applied playing versus a PS4 without the fix applied can cause a number of problems for the PS4 player, so you should probably stick to playing friends PC to PC.
On that, Altimor's appears to be working on a way to ensure PS4 and unmodded clients aren't plagued with more one-sided rollback than normal as a result of the mod. "I'm working on a fix that'll allow it to correct for both players when playing with an unmodded client," Altimor said.
There's also the issue of using a modded version of Street Fighter 5 for online play on PC, which you'd think would trigger a ban but so far seems to be fair game, at least according to reports from players.
"They could always decide to start banning for any code modification, but they currently don't," Altimor said.
The whole thing isn't exactly a good look for Capcom. Street Fighter 5 suffered a disastrous launch in 2016, the effects of which are still felt today. While the Japanese company has worked to improve matters, and DLC characters are still being released, it's clear the game's potential was never fully realised.
Fingers crossed the inevitable Street Fighter 6 does not suffer a similar fate.