Skip to content
New issue

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

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

Already on GitHub? # to your account

Add cvar for stamina restoration speed based on fps reference. #1005

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

Garey27
Copy link

@Garey27 Garey27 commented Aug 27, 2024

This PR fixes time to restore stamina after jump based on reference fps.

Which described on another PR:
#755

After setting cvar mp_stamina_restore_rate to “100.0”, players with no matter how high (1000) or low (30) fps will have the same stamina recovery rate after a jump as they would have with 100 fps.

@Vaqtincha
Copy link
Contributor

ifdef REGAMEDLL_ADD forget ?

@AlexSwartz
Copy link
Contributor

AlexSwartz commented Nov 22, 2024

Hello, I test this fix and there is some glitch when client FPS is greater than ~145FPS. When landing, there is a slight judder to the camera.

I tested with mp_stamina_restore_rate 100, with this merged to the latest release 5.26.0.668.

https://streamable.com/azz0gy

Edit:

Slow motion of the judder on landing with 500 fps:
https://streamable.com/icvrek

As FPS increases, the duration of the judder increases. I have measured the judder in slow motion and counted how long the judder lasts upon landing:

275FPS = judder duration 473ms
500FPS = judder duration 571ms
1000FPS = judder duration 624ms

@Garey27
Copy link
Author

Garey27 commented Dec 2, 2024

@AlexSwartz This because client predict your movement with original PM_Move code. (In Valve's client.dll library), and when server send you SVC_CLIENTDATA, client try to synchronize it to server's one, ideally all fixes in pm_* code should be replicated in client library.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants