docs.unity3d.com
    Show / Hide Table of Contents

    Struct DynamicsWorld

    A collection of motion information used during physics simulation.

    Inherited Members
    ValueType.Equals(Object)
    ValueType.GetHashCode()
    ValueType.ToString()
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetType()
    Namespace: Unity.Physics
    Syntax
    [NoAlias]
    public struct DynamicsWorld : IDisposable

    Constructors

    DynamicsWorld(Int32, Int32)

    Construct a dynamics world with the given number of uninitialized motions.

    Declaration
    public DynamicsWorld(int numMotions, int numJoints)
    Parameters
    Type Name Description
    Int32 numMotions

    Number of motions.

    Int32 numJoints

    Number of joints.

    Properties

    Joints

    Gets the joints.

    Declaration
    public readonly NativeArray<Joint> Joints { get; }
    Property Value
    Type Description
    NativeArray<Joint>

    The joints.

    MotionDatas

    Gets the motion datas.

    Declaration
    public readonly NativeArray<MotionData> MotionDatas { get; }
    Property Value
    Type Description
    NativeArray<MotionData>

    The motion datas.

    MotionVelocities

    Gets the motion velocities.

    Declaration
    public readonly NativeArray<MotionVelocity> MotionVelocities { get; }
    Property Value
    Type Description
    NativeArray<MotionVelocity>

    The motion velocities.

    NumJoints

    Gets the number of joints.

    Declaration
    public readonly int NumJoints { get; }
    Property Value
    Type Description
    Int32

    The total number of joints.

    NumMotions

    Gets the number of motions.

    Declaration
    public readonly int NumMotions { get; }
    Property Value
    Type Description
    Int32

    The total number of motions.

    Methods

    Clone()

    Clone the world.

    Declaration
    public DynamicsWorld Clone()
    Returns
    Type Description
    DynamicsWorld

    A copy of this object.

    Dispose()

    Free internal memory.

    Declaration
    public void Dispose()
    Implements
    IDisposable.Dispose()

    GetJointIndex(Entity)

    Gets the zero-based index of the joint.

    Declaration
    public int GetJointIndex(Entity entity)
    Parameters
    Type Name Description
    Entity entity

    The entity.

    Returns
    Type Description
    Int32

    The joint index.

    Reset(Int32, Int32)

    Resets this object.

    Declaration
    public void Reset(int numMotions, int numJoints)
    Parameters
    Type Name Description
    Int32 numMotions

    Number of motions.

    Int32 numJoints

    Number of joints.

    UpdateJointIndexMap()

    Updates the joint index map.

    Declaration
    public void UpdateJointIndexMap()
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023