Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rollback-based networking support for the platformer behavior #6

Open
arthuro555 opened this issue Aug 3, 2022 · 0 comments
Open
Labels
✨ Feature New feature or request
Milestone

Comments

@arthuro555
Copy link
Owner

The network is slow. Even on the speediest connections, there is a slight delay between a message sent from a client and the moment the server receives it. Especially on lower-grade connections, this delay can completely destroy a user's game experience: if a client sends a jump input a few moments before falling into a pit, if the delay is high enough, the server won't allow the jump to be done because he already fell off, even though it was valid at the time the player pressed the button.

To help with that, THNK would make snapshots of the platformer behavior's state every frame, e.g. The position of the character, and the platform it is standing on (if any), and save them for the last few server ticks. When it is time for the platformer behavior to handle inputs, we'll revert the state of the server to that of the tick at which the player did the input. That way, we can prevent unfair behavior due to latency 😎

@arthuro555 arthuro555 modified the milestones: THNK Beta, THNK Release Aug 3, 2022
@arthuro555 arthuro555 added the ✨ Feature New feature or request label Aug 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
✨ Feature New feature or request
Projects
Status: 🔙📋 Backlog
Development

No branches or pull requests

1 participant