s&
newspaperAbout
infoAbout s&box newspaperLatest News published_with_changesChanges mapRoadmap monitoringMetrics
gamesGames
sports_esportsBrowse Games rocketDiscover Games
business_centerWorkshop
sports_esportsGames landscapeMaps chairModels textureMaterials apparelClothing constructionMore..
forumForum docsDocs
docsDocumentation dashboardApi Reference
inputLog in with Steam chevron_leftChange Language
简体中文EnglishРусскийEspañolPortuguês-BrasilDeutsch日本語FrançaisPolskiTürkçe한국어PirateItalianoไทย繁體中文УкраїнськаČeštinaNederlandsMagyarDanskSuomiSvenskaNorskΕλληνικάRomânăБългарскиTiếng ViệtBahasa IndonesiaEspañol-Latinoaméricaالعربية
Api
Classes
PhysicsSettings
chevron_left Classes
class
PhysicsSettings

Constructors

functionsPhysicsSettings

Properties

data_objectFixedUpdateFrequencydata_objectMaxFixedUpdatesdata_objectSubStepsdata_objectUseFixedUpdate
menu
PhysicsSettings
class Sandbox.Physics .account_tree extends ConfigData
Sandbox.Engine

build Constructors 1

PhysicsSettings ()

data_object Properties 4

FixedUpdateFrequency
float
How many times a second FixedUpdate runs
MaxFixedUpdates
int
If the frame took longer than a FixedUpdate step, we need to run multiple steps for that frame, to catch up. How many are allowed? Too few, and the simluation will run slower than the game. If you allow an unlimited amount then the frame time could snowball to infinity and never catch up.
SubSteps
int
If you're seeing objects go through other objects or you have a low tickrate, you might want to increase the number of physics substeps. This breaks physics steps down into this many substeps. The default is 1 and works pretty good. Be aware that the number of physics ticks per second is going to be tickrate * substeps. So if you're ticking at 90 and you have SubSteps set to 1000 then you're going to do 90,000 steps per second. So be careful here.
UseFixedUpdate
bool
If false, then instead of operating physics, and UpdateFixed in a fixed update frequency they will be called the same as Update - every frame, with a variable time delta.

Inheritance

ConfigData
PhysicsSettings
people
Log in to reply
You can't reply if you're not logged in. That would be crazy.
  • News
  • Docs
  • Metrics
  • FAQ
  • Forum
  • Discord
  • Twitter