s&
About
The Project
info
About s&box
map
Roadmap
monitoring
Metrics
Engine startup and usage numbers
Updates
newspaper
Latest News
published_with_changes
Changes
Release-by-release changelog
Games
Browse Games
Discover Games
gamejams
Workshop
Playable
sports_esports
Games
Standalone games and gamemodes
Assets
landscape
Maps
view_in_ar
Models
texture
Materials
apparel
Clothing
apps
Everything
Every asset type in one list
Forum
Learn
Documentation
rocket_launch
Getting Started
docs
Documentation
api
API Reference
Resources
school
Tutorials
manage_search
Code Search
Get s&box
Sign in with Steam
Api
Classes
BallJointBuilder
chevron_left
Classes
class
BallJointBuilder
Properties
data_object
DampingRatio
data_object
EnableMotor
data_object
EnableSwingLimit
data_object
EnableTwistLimit
data_object
Frequency
data_object
Friction
data_object
MaxTorque
data_object
Motor
data_object
SwingLimit
data_object
TargetRotation
data_object
TargetVelocity
data_object
TwistLimit
Methods
functions
WithDampingRatio
functions
WithFrequency
functions
WithFriction
functions
WithMaxTorque
functions
WithSwingLimit
functions
WithTargetRotation
functions
WithTargetVelocity
functions
WithTwistLimit
BallJointBuilder
Builds a ball joint with optional swing and twist limits.
class
Sandbox
.
account_tree
extends
PhysicsJointBuilder
sealed
Sandbox.Engine
data_object
Properties
12
DampingRatio
float
Spring motor damping ratio.
EnableMotor
bool
Whether the joint's angular motor is enabled.
EnableSwingLimit
bool
Whether the joint enforces a swing angle limit.
EnableTwistLimit
bool
Whether the joint enforces a twist angle limit.
Frequency
float
Spring motor frequency in hertz.
Friction
float
Component-style friction, used when the motor is disabled.
MaxTorque
float
Maximum torque the velocity motor may apply.
Motor
MotorMode
The motor mode, matching the ball component.
SwingLimit
float
Maximum allowed swing angle in degrees.
TargetRotation
Rotation
Spring motor target rotation relative to the joint frames.
TargetVelocity
Vector3
World angular velocity for the motor, in radians per second.
TwistLimit
Vector2
Minimum and maximum allowed twist angles in degrees.
functions
Methods
8
WithDampingRatio
(
v
)
BallJointBuilder
WithFrequency
(
v
)
BallJointBuilder
WithFriction
(
v
)
BallJointBuilder
Sets friction and disables the motor.
WithMaxTorque
(
v
)
BallJointBuilder
WithSwingLimit
(
v
)
BallJointBuilder
Sets and enables the swing angle limit.
WithTargetRotation
(
rotation
)
BallJointBuilder
Sets and enables the target-rotation spring motor.
WithTargetVelocity
(
v
)
BallJointBuilder
Sets the target angular velocity and enables the motor.
WithTwistLimit
(
min
,
max
)
BallJointBuilder
Sets and enables the twist angle limits.
Inheritance
PhysicsJointBuilder
BallJointBuilder
people
Log in to reply
You can't reply if you're not logged in. That would be crazy.