{!See https://docs.google.com/document/d/1takg_GmIBBKKTj-GHZCwzxohpQz7Bhekivkk72kYMtE/edit for reference implementation of OneTrust, dataLayer and GTM} {!OneTrust Cookies Consent} {!OneTrust Cookies Consent end} {!dataLayer initialization push} {!dataLayer initialization push end} {!Google Tag Manager} {!Google Tag Manager end} Struct RigidBody | Unity Physics | 1.1.0-pre.3
docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Struct RigidBody

    An instance of a collider in a physics world.

    Implements
    ICollidable
    IAspectQueryable
    Inherited Members
    ValueType.Equals(object)
    ValueType.GetHashCode()
    ValueType.ToString()
    object.Equals(object, object)
    object.ReferenceEquals(object, object)
    object.GetType()
    Namespace: Unity.Physics
    Assembly: solution.dll
    Syntax
    public struct RigidBody : ICollidable, IAspectQueryable

    Fields

    Name Description
    Collider

    The rigid body's collider (allowed to be null)

    CustomTags

    Arbitrary custom tags. These get copied into contact manifolds and can be used to inform contact modifiers.

    Entity

    The entity that rigid body represents.

    Scale

    The rigid body's scale in world space.

    WorldFromBody

    The rigid body's transform in world space.

    Zero

    Rigid body that thas identity transform, null entity, and a null collider.

    Methods

    Name Description
    BoxCast(float3, quaternion, float3, float3, float, out ColliderCastHit, CollisionFilter, QueryInteraction)

    Box cast.

    BoxCast(float3, quaternion, float3, float3, float, CollisionFilter, QueryInteraction)

    Box cast.

    BoxCastAll(float3, quaternion, float3, float3, float, ref NativeList<ColliderCastHit>, CollisionFilter, QueryInteraction)

    Box cast all.

    BoxCastCustom<T>(float3, quaternion, float3, float3, float, ref T, CollisionFilter, QueryInteraction)

    Box cast custom.

    CalculateAabb()

    Calculates the aabb.

    CalculateDistance(in ColliderAspect, float, ref NativeList<DistanceHit>, QueryInteraction)

    Calculates the distance from the input aspect.

    CalculateDistance(in ColliderAspect, float, out DistanceHit, QueryInteraction)

    Calculates the distance from the input aspect.

    CalculateDistance(in ColliderAspect, float, QueryInteraction)

    Calculates the distance from the input aspect.

    CalculateDistance(ColliderDistanceInput)

    Calculates the distance.

    CalculateDistance(ColliderDistanceInput, ref NativeList<DistanceHit>)

    Calculates the distance.

    CalculateDistance(ColliderDistanceInput, out DistanceHit)

    Calculates the distance.

    CalculateDistance(PointDistanceInput)

    Calculates the distance.

    CalculateDistance(PointDistanceInput, ref NativeList<DistanceHit>)

    Calculates the distance.

    CalculateDistance(PointDistanceInput, out DistanceHit)

    Calculates the distance.

    CalculateDistance<T>(in ColliderAspect, float, ref T, QueryInteraction)

    Calculates the distance from the input aspect.

    CalculateDistance<T>(ColliderDistanceInput, ref T)

    Calculates the distance.

    CalculateDistance<T>(PointDistanceInput, ref T)

    Calculates the distance.

    CapsuleCast(float3, float3, float, float3, float, out ColliderCastHit, CollisionFilter, QueryInteraction)

    Capsule cast.

    CapsuleCast(float3, float3, float, float3, float, CollisionFilter, QueryInteraction)

    Capsule cast.

    CapsuleCastAll(float3, float3, float, float3, float, ref NativeList<ColliderCastHit>, CollisionFilter, QueryInteraction)

    Capsule cast all.

    CapsuleCastCustom<T>(float3, float3, float, float3, float, ref T, CollisionFilter, QueryInteraction)

    Capsule cast custom.

    CastCollider(in ColliderAspect, float3, float, ref NativeList<ColliderCastHit>, QueryInteraction)

    Cast another collider aspect against this RigidBody.

    CastCollider(in ColliderAspect, float3, float, out ColliderCastHit, QueryInteraction)

    Cast another collider aspect against this RigidBody.

    CastCollider(in ColliderAspect, float3, float, QueryInteraction)

    Cast another collider aspect against this RigidBody.

    CastCollider(ColliderCastInput)

    Cast collider.

    CastCollider(ColliderCastInput, ref NativeList<ColliderCastHit>)

    Cast collider.

    CastCollider(ColliderCastInput, out ColliderCastHit)

    Cast collider.

    CastCollider<T>(in ColliderAspect, float3, float, ref T, QueryInteraction)

    Cast another collider aspect against this one.

    CastCollider<T>(ColliderCastInput, ref T)

    Cast collider.

    CastRay(RaycastInput)

    Cast ray.

    CastRay(RaycastInput, ref NativeList<RaycastHit>)

    Cast ray.

    CastRay(RaycastInput, out RaycastHit)

    Cast ray.

    CastRay<T>(RaycastInput, ref T)

    Cast ray.

    CheckBox(float3, quaternion, float3, CollisionFilter, QueryInteraction)

    Check box.

    CheckCapsule(float3, float3, float, CollisionFilter, QueryInteraction)

    Check capsule.

    CheckSphere(float3, float, CollisionFilter, QueryInteraction)

    Checks if a sphere overlaps with this body.

    OverlapBox(float3, quaternion, float3, ref NativeList<DistanceHit>, CollisionFilter, QueryInteraction)

    Overlap box.

    OverlapBoxCustom<T>(float3, quaternion, float3, ref T, CollisionFilter, QueryInteraction)

    Overlap box custom.

    OverlapCapsule(float3, float3, float, ref NativeList<DistanceHit>, CollisionFilter, QueryInteraction)

    Overlap capsule.

    OverlapCapsuleCustom<T>(float3, float3, float, ref T, CollisionFilter, QueryInteraction)

    Overlap capsule custom.

    OverlapSphere(float3, float, ref NativeList<DistanceHit>, CollisionFilter, QueryInteraction)

    Overlap sphere.

    OverlapSphereCustom<T>(float3, float, ref T, CollisionFilter, QueryInteraction)

    Overlap sphere custom.

    SphereCast(float3, float, float3, float, out ColliderCastHit, CollisionFilter, QueryInteraction)

    Sphere cast.

    SphereCast(float3, float, float3, float, CollisionFilter, QueryInteraction)

    Sphere cast.

    SphereCastAll(float3, float, float3, float, ref NativeList<ColliderCastHit>, CollisionFilter, QueryInteraction)

    Sphere cast all.

    SphereCastCustom<T>(float3, float, float3, float, ref T, CollisionFilter, QueryInteraction)

    Sphere cast custom.

    In This Article
    Back to top
    Copyright © 2023 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)