Skip to content

RigidBodyComponent

class · namespace Hazel · Component

Inherits Component

public class RigidBodyComponent : Component

Properties

AngularDrag

public float AngularDrag { get; set; }

AngularVelocity

public Vector3 AngularVelocity { get; set; }

BodyType

public EBodyType BodyType { get; set; }

IsGravityEnabled

public bool IsGravityEnabled { get; set; }

IsSleeping

public bool IsSleeping { get; set; }

IsTrigger

public bool IsTrigger { get; set; }

Layer

public uint Layer { get; set; }

LayerName

public string LayerName { get; set; }

LinearDrag

public float LinearDrag { get; set; }

LinearVelocity

public Vector3 LinearVelocity { get; set; }

Mass

public float Mass { get; set; }

MaxAngularVelocity

public float MaxAngularVelocity { get; set; }

MaxLinearVelocity

public float MaxLinearVelocity { get; set; }

Methods

AddForce(Vector3, EForceMode)

public void AddForce(Vector3 force, EForceMode forceMode = EForceMode.Force)

AddForceAtLocation(Vector3, Vector3, EForceMode)

public void AddForceAtLocation(Vector3 force, Vector3 location, EForceMode forceMode = EForceMode.Force)

AddTorque(Vector3, EForceMode)

public void AddTorque(Vector3 torque, EForceMode forceMode = EForceMode.Force)

GetLockedAxes()

public uint GetLockedAxes()

IsAxisLocked(EActorAxis)

public bool IsAxisLocked(EActorAxis axis)

MoveKinematic(Vector3, Vector3, float)

public void MoveKinematic(Vector3 targetPosition, Vector3 targetRotation, float deltaSeconds)

Rotate(Vector3)

public void Rotate(Vector3 rotation)

SetAxisLock(EActorAxis, bool, bool)

public void SetAxisLock(EActorAxis axis, bool value, bool forceWake = false)

Source: Hazel/Scene/Components.cs