If I have a UPROPERTY that’s replicated, and modify the value on the client, the server will replicate its own changes down to the client while the client may still be predicting ahead. If you were to display this value to a player, you’d see the value jitter between the locally predicted value and the authority replicated value if you’re repeating the same prediction.
I lose 1 boost unit every time I boost, if I’m boosting repeatedly faster than the server acks each boost and replicates the subtraction down, it stomps my current pending prediction and subsequent predictions even though the client is correctly predicting.
Bunch of solutions for this, no silver bullet. Most basic one is Ive seen is the client assumes the predicted property is always right and the rep conditions to skip the owner/autonomous proxy player. When they do a prediction they send the property result value in the request, and then if the server sees a misprediction, a RPC “correction” is sent. Movement system works very similarly.
However
Unreal Gameplay Ability System uses a more complex and robust FPredictionKey to track deltas on a property for an ability’s result. This reconciles on the client when the ability’s result is confirmed by the server using said key. Seems fairly straight forward concept, it’s the same idea as the correction RPC, but it handles abilities generically and tackles a lot of implementation details such as dependency rollbacks.
I’m curious if anyone uses an alternative method that’s hand rolled or some other UE out of box trick I’m not aware of.