Live data from Hacker News

How fighting games use delay-based and rollback netcode (2019)

ki.infil.net

81–90 of 107 posts

Re: How fighting games use delay-based and rollback netcode (2019)

#81
post #63

Does anyone know if rollback netcode works well in a 20+ player shooter game? I curious because the current craze of Battle Royals seems really taxing to the whole re-simulation of multiple frames within the window of a single frame. Without being any less subtle, games like Apex Legends is known for really bad server performance, latency, and among other things.

Overwatch uses a rollback model but it’s not inherently or obviously better than other games.

It uses a fairly standard netcode where the state on a server is the only correct one. Battlefield 4 for example has a preference of a client state over the server in hit registration.

Re: How fighting games use delay-based and rollback netcode (2019)

#82
post #59

Earlier quoted context omitted.

You shouldn't be disappointed. Nothing has changed is overwhelmingly the correct answer. It is incredibly jarring to assume a remote player takes an action, display them taking that action, then roll back when you realize they didn't. From your local perspective, it looks like they blocked for a few frames, which makes you assume they're going to block, then they flash back to being defenseless, and your attack weird…

Yeah it probably is an optimal strategy (and certainly relative to return on investment). I didn't mean disappointment that the tech hadn't advanced, I meant that my expectations were set really high by the grandparent comment ("Neural networks? In 2006? Surely not! But it must be something really fancy, judging by all these flowcharts!" [0]) and by how they kept hyping up the "prediction algorithm" for half the arti…

I think you're missing the point of the article (and the material you included). It's not that the method of inference is that interesting, its the fact that the game is able to make use of that inference at all. Every thing else about the algorithm is interesting: rollback, reconciliation, (de)synchronization, choice of delay, the the separation of game logic from rest of the game loop, etc. As the article details, it's extremely complex to do this right, to the point where many games just don't bother trying.

Think about the time scale under which this prediction is made: 60Hz. Even the best players do not change input at nearly that rate. So it's clear that the current value is going to be the best estimate for the next value. That realization doesn't even begin to solve the problem though!

Re: How fighting games use delay-based and rollback netcode (2019)

#83

Earlier quoted context omitted.

Overwatch uses a rollback model but it’s not inherently or obviously better than other games.

It uses a fairly standard netcode where the state on a server is the only correct one. Battlefield 4 for example has a preference of a client state over the server in hit registration.

Yes but the game is deterministic and trades inputs which are rewound and resimulated. I don’t think the interesting part of rollback net code in fighting games is that it’s usually peer-to-peer. There’s a GDC talk on how it works here:

https://www.youtube.com/watch?v=W3aieHjyNvw

Re: How fighting games use delay-based and rollback netcode (2019)

#84
I'm glad this has been done more recently, and even been expanded to other genres, like the upcoming Knockout City which will apparently feature some sort of rollback netcode[1]. I've been playing Lethal League Blaze, and playing against people with 80 to 150 ping is possible, and doesn't feel horrible which is wild, since in other genres that have to rely on dedicated servers to be somewhat decent like CS:GO or Valorant, anything above 50 or 60 ping (to the server, not the other players) is pretty jarring to experience.

[1]https://www.nintendoenthusiast.com/knockout-city-is-the-wild... (only mentioned in one sentence)

Re: How fighting games use delay-based and rollback netcode (2019)

#85
post #25

Does anyone know how Fall Guy's net code was implemented? It's very smooth with 100 participants.

Based on Fall Guy's hiring page, which asked for experience with Photon, it's probably this: https://www.photonengine.com/en/pun

Could be using Photon but I don't think Photon solves this particular problem as far as I know. Did you see something in particular that mentions that as a feature?

Re: How fighting games use delay-based and rollback netcode (2019)

#86
post #38

Earlier quoted context omitted.

Where did you get the thing about neural networks? I read your comment before reading the article and was really disappointed the prediction "algorithm" (pioneered by GGPO in 2006 [0] and still used today) is literally "assume nothing changed", ie. the opponent is still holding down the same keys as the last frame. [0]: magazine article by the author of GGPO [pdf] https://drive.google.com/file/d/1cV0fY8e_SC1hIFF5E1rT…

You shouldn't be disappointed. Nothing has changed is overwhelmingly the correct answer. It is incredibly jarring to assume a remote player takes an action, display them taking that action, then roll back when you realize they didn't. From your local perspective, it looks like they blocked for a few frames, which makes you assume they're going to block, then they flash back to being defenseless, and your attack weird…

This is a lovely illustration of the fact that "not very powerful but highly predictable" is often far better than "powerful but unpredictable" when it comes to tools.

Re: How fighting games use delay-based and rollback netcode (2019)

#87
I was linked here by a friend. There's a lot of thoughts in the discussion about how and if input prediction could be made more sophisticated, maybe using machine learning.

This is actually the topic of a degree project I've been working on for the past year, and I hope to finalize the report next month and publish the code on github soon. The tldr is that it seems to take a lot of additional complexity for the improvement you get, and it is currently unknown how "false positive" predictions (ie when the model predicts a new buttonpress that doesn't happen) affect the user experience (but intuitively it seems like it would be worse than the false negatives we currently experience). In other words, we don't know if it would actually feel any better to play even if, say, the prediction accuracy is slightly higher. That said, this is only a first attempt and who knows how much it could be improved.

I'll probably post more about it as @zeknife on twitter next month.

Re: How fighting games use delay-based and rollback netcode (2019)

#88

Earlier quoted context omitted.

It uses a fairly standard netcode where the state on a server is the only correct one. Battlefield 4 for example has a preference of a client state over the server in hit registration.

Yes but the game is deterministic and trades inputs which are rewound and resimulated. I don’t think the interesting part of rollback net code in fighting games is that it’s usually peer-to-peer. There’s a GDC talk on how it works here: https://www.youtube.com/watch?v=W3aieHjyNvw

I know how it works. The only major difference for FPS is that there are multiple inputs inside a frame which have to be precisely timed. All the prediction models are either deceiving for a false reaction or the same "keep doing the previous action".

Re: How fighting games use delay-based and rollback netcode (2019)

#89
post #23

Earlier quoted context omitted.

The fact that they were able to optimize two frames of input lag away to make the online gameplay have the same latency as offline is itself incredible. As far as I know, even other rollback-equipped fighting games still add a little bit of latency in order to play online without requiring constant rollbacks. That said, Melee is also a game that is very hard on the rollback, because movement and attack startup are fa…

AFAIK they didn't do anything special to save two frames, just a CRT (which is what's used on LAN) has 2 frames of lag.

Melee has 3 frames of lag on a CRT, none of which come from the CRT.

They managed to pare it down to only one frame.

Re: How fighting games use delay-based and rollback netcode (2019)

#90
post #56
post #48

Earlier quoted context omitted.

Haha! That's exciting to see something like that shared across industries. I use it for medical health records to ensure we track every single change and know when something changed. Pairs really nicely with dynamodb in aws.

Could you talk a little about that or point to something that details the overall strategy? I'm considering a similar setup for event sourcing in AWS and DynamoDb with change streams crossed my mind.

We use event sourcing in a business application.

Event sourcing, at it's core, is making sure your source of truth is a log of events and your app state is derived from that.

Beyond those constraints, there are many variations of how it can be done, each with very different tradeoffs.

Post reply on HN