backroll-rs
backroll-rs copied to clipboard
Make framerate / TPS configurable
See:
https://github.com/HouraiTeahouse/backroll-rs/blob/3c6bdc08a17d2f4e87524595a935d7f28de8e7a4/backroll/src/protocol/mod.rs#L38
which is used for estimating the remote player's frame for timesyncing purposes:
https://github.com/HouraiTeahouse/backroll-rs/blob/3c6bdc08a17d2f4e87524595a935d7f28de8e7a4/backroll/src/protocol/mod.rs#L740-L753
On an unrelated note, it that calculation correct? The comment seems to suggest round_trip_time.as_secs() / 2
.
For most 60FPS games this is likely OK, but this should really be configurable.
This was directly ported from GGPO. The calculation does seem to be off. We should have a divide by two there.
The RTT computation should be fixed now as of #15.