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

Use dynamic frameRate instead of locking to 60fps #319

Merged
merged 3 commits into from Dec 10, 2023

Conversation

DanielMartinus
Copy link
Owner

@DanielMartinus DanielMartinus commented Dec 10, 2023

Updated the variable speedF to frameRate to better reflect what it does.

Before this variable was locked to 60fps. This variable is used to scale the particles movements (and other properties) based on the frame rate, this explains why it's moving two times slower on 120fps and probably two times faster on 30fps.

This value is now updated based on the deltaTime (time between frames) to account for different frame rates.

Fixes #314

@DanielMartinus DanielMartinus merged commit 9b2441a into main Dec 10, 2023
1 check passed
@DanielMartinus DanielMartinus deleted the add-dynamic-framerate branch December 10, 2023 20:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

different animation effect Issue on multiple devices
1 participant