HingeJointBuilderclass

Builds a hinge joint that rotates around one axis.

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

Methods7

Showing 7 methods

public Sandbox.HingeJointBuilder WithTargetAngle(float angle)PUBLIC

Sets and enables the target-angle spring motor.

ParameterTypeDescription
anglefloat—

public Sandbox.HingeJointBuilder WithTwistLimit(float min, float max)PUBLIC

Sets and enables the twist angle limits.

ParameterTypeDescription
minfloatThe minimum twist angle in degrees.
maxfloatThe maximum twist angle in degrees.

Properties10

Showing 10 properties

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

Spring motor damping ratio.

Returns:float—

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

Whether the hinge's angular motor is enabled.

Returns:bool—

public bool Sandbox.HingeJointBuilder.EnableTwistLimit { get; set; }PUBLICGETSET

Whether the hinge enforces a twist angle limit.

Returns:bool—

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

Spring motor frequency in hertz.

Returns:float—

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

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

Returns:float—

public float Sandbox.HingeJointBuilder.MaxTorque { get; set; }PUBLICGETSET

Maximum torque the velocity motor may apply.

Returns:float—

public float Sandbox.HingeJointBuilder.TargetAngle { get; set; }PUBLICGETSET

Spring motor target angle in degrees.

Returns:float—

public Vector3 Sandbox.HingeJointBuilder.TargetVelocity { get; set; }PUBLICGETSET

World angular velocity for the motor, in radians per second.

Returns:Vector3—

On this page