SliderJointBuilderclass

Builds a slider joint that moves along one axis.

object→PhysicsJointBuilder→SliderJointBuilder
Namespace
Sandbox
Assembly
Sandbox.Engine
Declaration
public sealed class Sandbox.SliderJointBuilder : Sandbox.PhysicsJointBuilder

Methods7

Showing 7 methods

public Sandbox.SliderJointBuilder WithLimit(float min, float max)PUBLIC

Sets and enables the translation limits.

ParameterTypeDescription
minfloatThe minimum translation along the joint axis.
maxfloatThe maximum translation along the joint axis.

public Sandbox.SliderJointBuilder WithTargetPosition(float position)PUBLIC

Sets and enables the target-position spring motor.

ParameterTypeDescription
positionfloat—

Properties10

Showing 10 properties

public float Sandbox.SliderJointBuilder.DampingRatio { get; set; }PUBLICGETSET

Spring motor damping ratio.

Returns:float—

public bool Sandbox.SliderJointBuilder.EnableLimit { get; set; }PUBLICGETSET

Whether the joint enforces a translation limit along its axis.

Returns:bool—

public bool Sandbox.SliderJointBuilder.EnableMotor { get; set; }PUBLICGETSET

Whether a velocity or position motor is enabled.

Returns:bool—

public float Sandbox.SliderJointBuilder.Frequency { get; set; }PUBLICGETSET

Spring motor frequency in hertz.

Returns:float—

public float Sandbox.SliderJointBuilder.Friction { get; set; }PUBLICGETSET

Component-style friction, used when the motor is disabled.

Returns:float—

public float Sandbox.SliderJointBuilder.MaxForce { get; set; }PUBLICGETSET

Maximum force the velocity motor may apply.

Returns:float—

public float Sandbox.SliderJointBuilder.TargetPosition { get; set; }PUBLICGETSET

Spring motor target offset along the slider axis.

Returns:float—

On this page