Jump to content

  • Log In with Google      Sign In   
  • Create Account


Member Since 06 Apr 2014
Offline Last Active Jun 22 2015 12:24 PM

#5144897 FPS on UNREAL - GGPO or other prediction netcode?

Posted by on 06 April 2014 - 10:18 PM

A little something from Antic over at the ROTN forum:


Yea, far as netcode/prediction, it all works essentially the same, but with specific differences in the way it’s handled.
“- Hit detect the actual situation on the server. This is more resistant to cheating and unfairness, but means that players must compensate for whatever the extrapolation/prediction algorithm is.”
For sure you want hit detection to be handled by the server, client-side dictated hit detection is easily hackable as many games have seen, as is any client-side dictated data (borderlands hacked guns for example). Basically you have to represent what the server sees to the client, which means they have to compensate for your prediction code.
Any “unlagged” mods use a form of client-side prediction by drawing the client and other clients where they’re “going to be” by predicting where they will end up based on their trajectories and speeds, etc. Problem is, they can and probably will change based on client input, like suddenly changing direction to dodge a shot.
To represent the moment when the client’s perception of object positions is updated to match the server’s actual positioning of objects, you usually run into 2 possibilities. One, is snapping or rubber-banding of an object from it’s current drawn position to its “real” position. The other is using no prediction whatsoever and running into more client-side “lag”.
If you had to compare the 2 systems, prediction code and realistic positioning, QL and games like Diablo 3 or Path of Exile are examples of different kinds of prediction code. Q3 vanilla or Q3 osp mod would be examples of little to no prediction code, and thus lag.
It’s almost impossible to run no prediction code whatsoever, but you have to be careful how you choose to implement it as it can totally ruin the feel of what players think they’re shooting at / hits registering “correctly”.
In Diablo 3, rubber-banding is frustrating because you run forward a good ways then all of a sudden, Bam, you never left, you’re right back in the shit. Path of Exile’s “Desync” is basically giving the client free reign over prediction, leading to issues where you think you’re somewhere and you’re not, then the server eventually syncs up and the invisible damage you were taking turns out to be 3 monsters that were hitting you the whole time on the server. Path’s system would actually work decently if the servers could handle CONSTANT updates or refreshes to the clients, but it doesn’t, and at best they resync every 10 seconds. A lot can happen in 10 seconds. Run into a monster or a wall on the server, when your client showed no problem, and on your screen you’re running free, on the server you stopped dead because you were blocked.
QLive’s prediction code is evidenced in the fact that the model is almost always drawn ahead of the actual player based on their current trajectory, thus aiming behind the model becomes efficient in hitting them. When the game was first released/beta, this was complained about heavily. This also leads to many “around corner” shots, when someone thinks they strafed around the corner, but in fact their real model was still out in the open. This also leads to the mythical “shoot-thru”, where the player shoots the model on their screen, but in fact they were missing the real player, leading to a feeling of being cheated. Shoot-thrus don’t really happen, they’re simply a player’s mistaking their client version for the real location of their target, when the system has been designed this way from the start.



Clan Leader, ROTN (Revenge of the Noobz) Quake Live
Lead Project Manager - FPS Shooter