s&
About
The Project
infoAbout s&box mapRoadmap monitoringMetricsEngine startup and usage numbers
Updates
newspaperLatest News published_with_changesChangesRelease-by-release changelog
Games
Browse Games Discover Games
gamejams
Workshop
Playable
sports_esportsGamesStandalone games and gamemodes
Assets
landscapeMaps view_in_arModels textureMaterials apparelClothing
appsEverythingEvery asset type in one list
Forum
Learn
Documentation
rocket_launchGetting Started docsDocumentation apiAPI Reference
Resources
schoolTutorials manage_searchCode Search
Get s&box
Sign in with Steam
Api
Classes
SliderJointBuilder
chevron_left Classes
class
SliderJointBuilder

Properties

data_objectDampingRatiodata_objectEnableLimitdata_objectEnableMotordata_objectFrequencydata_objectFrictiondata_objectLimitdata_objectMaxForcedata_objectMotordata_objectTargetPositiondata_objectTargetVelocity

Methods

functionsWithDampingRatiofunctionsWithFrequencyfunctionsWithFrictionfunctionsWithLimitfunctionsWithMaxForcefunctionsWithTargetPositionfunctionsWithTargetVelocity
SliderJointBuilder
Builds a slider joint that moves along one axis.
class Sandbox .account_tree extends PhysicsJointBuilder
sealedSandbox.Engine

data_object Properties 10

DampingRatio
float
Spring motor damping ratio.
EnableLimit
bool
Whether the joint enforces a translation limit along its axis.
EnableMotor
bool
Whether a velocity or position motor is enabled.
Frequency
float
Spring motor frequency in hertz.
Friction
float
Component-style friction, used when the motor is disabled.
Limit
Vector2
The minimum and maximum allowed translation along the joint axis.
MaxForce
float
Maximum force the velocity motor may apply.
Motor
MotorMode
The motor mode, matching the slider component.
TargetPosition
float
Spring motor target offset along the slider axis.
TargetVelocity
Vector3
World linear velocity for the motor, in units per second.

functions Methods 7

WithDampingRatio (v)
SliderJointBuilder
WithFrequency (v)
SliderJointBuilder
WithFriction (v)
SliderJointBuilder
Sets friction and disables the motor.
WithLimit (min, max)
SliderJointBuilder
Sets and enables the translation limits.
WithMaxForce (v)
SliderJointBuilder
WithTargetPosition (position)
SliderJointBuilder
Sets and enables the target-position spring motor.
WithTargetVelocity (v)
SliderJointBuilder
Sets and enables the velocity motor.

Inheritance

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