-
Notifications
You must be signed in to change notification settings - Fork 5
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
Max physics delta time is locked to 0.02 on lossless warp #20
Comments
Physics delta time is not the same as lossless warp |
That's correct, it isn't. But why is the setting "Max physics delta time per frame" locked into 0.02? In case you don't know what this setting does, here's a nice explanation: TLDR:
So why is a time warp mod forcing the game to draw a gameplay frame between every physics frame? |
It only does that when Timescale is one (ie: no warping). I didn't write this, and would have to research it a bit. It may be a holdover from an earlier version of the game. And yes, I do know what the setting does. |
Just an FYI, it's entirely possible that changing that can really mess things up. The mod is written around the idea of the timestep being 0.02, if it's not, then odd things may happen. This will need extensive testing to be sure |
Ideas: Where lossy (normal) time warp increases the timestep size, an ideal lossless warp should just calculate more physics frames in the same time period. Gameplay frames per real time second would stay the same and it would just fit more physics frames between two gameplay frames. So if the user has selected 0.02 as the max physics delta time (max 1 physics frame between gameplay frames), then it would compute 2 phys frames at 2x time warp, 4 phys frames at 4x time warp and so on. If the user has selected 0.06 as the max physics delta time (3 physics frames between gameplay frames), then it would compute 6 phys frames at 2x time warp, 12 phys frames at 4x time warp and so on. This is assuming lossless warp accuracy of 1. On lower accuracies the timestep would be longer and amount of computed physics frames lower. |
This setting which lets us do more physics frames per gameplay frame is now locked into 0.02. This forces the game to draw a gameplay frame on every physics frame, improving framerate but slowing physics down on slower computers. I don't see how adding more gameplay frames is relevant to lossless warp, which should ideally just calculate an adjustable amount of physics frames for one gameplay frame.
The text was updated successfully, but these errors were encountered: