sourencho / ungroup_game

A multiplayer game about temporary alliances written with a custom engine in C++ and SFML

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Improve interpolation

sourencho opened this issue · comments

Interpolation is not great right now...

I've had to disable replay in #114 because it was making things worse. Worth investigating if it's not coded properly.

https://github.com/SourenP/ungroup_game/blob/d157d4a03d529cb0546f1492fc8f9fcc5bcc55c5/src/common/util/game_settings.hpp#L14

I think we are currently doing "Dead Reckoning" (+Replay if we turn it on), but instead maybe we should do "Entity interpolation". See https://www.gabrielgambetta.com/entity-interpolation.html
With "Entity Interpolation" we would be lerping towards the game state instead of applying it outright. That way we smoothly transition into the true state.

Don't forget to read up on the networking links in the readme 😄

Can you describe what specific issues you're seeing with interpolation currently and what the preferred behavior would be?

There seems to be jitter with the current implementation of rewind+replay (ebb06c7)