Skip to content

Client side predictive input #21

@qxjit

Description

@qxjit

Allow client to predict results of its own input before server have processed the change.

This works correctly assuming only 1 player is making changes. Currently it will ignore any changes from other users until back in sync with the server.

*** Here is what currently happens on client A

Client A Submits a change at Tick 33
Client A begins drawing using input prediction
The server responds, telling the client it's change will be included in Tick 37
Client A will continue drawing using input prediction until it receives Tick 37
Client A receives Tick 37 -> it draws it and is now in sync with the server.
Client A stops using input prediction


If Client B submits a change that gets included in tick 34, currently client A will not display that change until Tick 37, because it uses input prediction to simulate ticks 34, 35 and 36, ignoring those ticks from the server.

Come up with a better strategy for displaying both predicted results of input and changes from the server.

Ideally when only one user IS making changes, it should behave as it does now (i.e. the results of the users change should ultimately be authoritative for everyone).

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions