-
Notifications
You must be signed in to change notification settings - Fork 24
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
Cursor Lerp Smoothing #223
Conversation
Looks good. |
The main issue is that all data related to the position evaluation and the evaluation itself should not be in the player state (broken SRP - high maintainability cost). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please address this issue first: #223 (comment)
Yea I can move the getter code to the drawing, the only problem is that the data has to be modified when receiving the packet. |
That's a good question, I was thinking for a while, seems like the cursor time must be a part of the state for sure. Btw, thanks for the contribution! That's really nice to see🙂 |
No problem for the contribution. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work👍
Adds smoothing for cursor.
Its a simple lerp between the prev and newest packet.
This means that the cursor is always acting 1 packet behind but this should be fine.