Jump to content

Query the user's settings choices: minimum physics ticks per second.


Recommended Posts

Does anyone know how to ask the KSP API to tell you what the user setting is on the main KSP settings screen for the minimum number of physics ticks per second?

I'm wanting a way to make a mod behave "nice" by limiting how much work it allows itself to do per update before returning, and scaling the amount of work it chooses to do based on that user setting.

Link to comment
Share on other sites

At a rough guess you should be able to read GameSettings.PHYSICS_FRAME_DT_LIMIT

Also, the setting is not the minimum number of physics ticks per second, it is the maximum time increment per physics tick so its reciprocal (1/x) is the minimum number of physics ticks per second you are after...

Edited by Padishar
Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...