Table of Contents

Class HingeConstraint

Namespace
Stride.Physics
Assembly
Stride.Physics.dll
public class HingeConstraint : Constraint, IDisposable, IRelative
Inheritance
HingeConstraint
Implements
Inherited Members
Extension Methods

Properties

AngularOnly

Gets or sets a value indicating whether [angular only].

public bool AngularOnly { get; set; }

Property Value

bool

true if [angular only]; otherwise, false.

HingeAngle

Gets the hinge angle.

public float HingeAngle { get; }

Property Value

float

The hinge angle.

LimitSign

Gets the limit sign.

public float LimitSign { get; }

Property Value

float

The limit sign.

LowerLimit

Gets the lower limit.

public float LowerLimit { get; }

Property Value

float

The lower limit.

MaxMotorImpulse

Gets or sets the maximum motor impulse.

public float MaxMotorImpulse { get; set; }

Property Value

float

The maximum motor impulse.

MotorTargetVelocity

Gets the motor target velocity.

public float MotorTargetVelocity { get; }

Property Value

float

The motor target velocity.

SolveLimit

Gets the solve limit.

public int SolveLimit { get; }

Property Value

int

The solve limit.

UpperLimit

Gets the upper limit.

public float UpperLimit { get; }

Property Value

float

The upper limit.

Methods

EnableAngularMotor(bool, float, float)

Enables the angular motor.

public void EnableAngularMotor(bool enableMotor, float targetVelocity, float maxMotorImpulse)

Parameters

enableMotor bool

if set to true [enable motor].

targetVelocity float

The target velocity.

maxMotorImpulse float

The maximum motor impulse.

EnableMotor(bool)

Enables the motor.

public void EnableMotor(bool enableMotor)

Parameters

enableMotor bool

if set to true [enable motor].

SetAxis(Vector3)

Sets the hinge axis for body A (this works mostly for body-world constraints).

public void SetAxis(Vector3 axisInA)

Parameters

axisInA Vector3

The hinge axis.

SetFrames(Matrix, Matrix)

Sets the frames.

public void SetFrames(Matrix frameA, Matrix frameB)

Parameters

frameA Matrix

The frame a.

frameB Matrix

The frame b.

SetLimit(float, float)

Sets the limit.

public void SetLimit(float low, float high)

Parameters

low float

The low.

high float

The high.

SetLimit(float, float, float)

Sets the limit.

public void SetLimit(float low, float high, float softness)

Parameters

low float

The low.

high float

The high.

softness float

The softness.

SetLimit(float, float, float, float)

Sets the limit.

public void SetLimit(float low, float high, float softness, float biasFactor)

Parameters

low float

The low.

high float

The high.

softness float

The softness.

biasFactor float

The bias factor.

SetLimit(float, float, float, float, float)

Sets the limit.

public void SetLimit(float low, float high, float softness, float biasFactor, float relaxationFactor)

Parameters

low float

The low.

high float

The high.

softness float

The softness.

biasFactor float

The bias factor.

relaxationFactor float

The relaxation factor.

SetMotorTarget(Quaternion, float)

Sets the motor target.

public void SetMotorTarget(Quaternion qAinB, float dt)

Parameters

qAinB Quaternion

The q ain b.

dt float

The dt.

SetMotorTarget(float, float)

Sets the motor target.

public void SetMotorTarget(float targetAngle, float dt)

Parameters

targetAngle float

The target angle.

dt float

The dt.