UnityEngine.PhysicsModule
The Physics module implements 3D physics in Unity.
Read time 5 minutesLast updated 3 hours ago
Definition
- Type: Module
Classes
Class | Description |
|---|---|
| ArticulationBody | A body that forms part of a Physics articulation. |
| BoxCollider | A box-shaped primitive collider. |
| CapsuleCollider | A capsule-shaped primitive collider. |
| CharacterController | A CharacterController allows you to easily do movement constrained by collisions without having to deal with a rigidbody. |
| CharacterJoint | Character Joints are mainly used for Ragdoll effects. |
| Collider | A base class of all colliders. |
| Collision | Describes a collision. |
| ConfigurableJoint | The configurable joint is an extremely flexible joint giving you complete control over rotation and linear motion. |
| ConstantForce | A force applied constantly. |
| ControllerColliderHit | ControllerColliderHit is used by CharacterController.OnControllerColliderHit to give detailed information about the collision and how to deal with it. |
| FixedJoint | The Fixed joint groups together 2 rigidbodies, making them stick together in their bound position. |
| HingeJoint | The HingeJoint groups together 2 rigid bodies, constraining them to move like connected by a hinge. |
| ImmediatePhysics | This class contains methods to run the immediate simulation steps. |
| Joint | Joint is the base class for all joints. |
| MeshCollider | A Collider that takes a Mesh asset and builds its collision shape based on it. |
| Physics | Global physics properties and helper methods. |
| PhysicsMaterial | Physics material describes how to handle colliding objects (friction, bounciness). |
| PhysicsSceneExtensions | Scene extensions to access the underlying physics scene. |
| Rigidbody | Control of an object's position through physics simulation. |
| SphereCollider | A sphere-shaped primitive collider. |
| SpringJoint | The spring joint ties together 2 rigid bodies, spring forces will be automatically applied to keep the object at the given distance. |
Structs
Struct | Description |
|---|---|
| ArticulationDrive | Drive applies forces and torques to the connected bodies. |
| ArticulationJacobian | The floating point dense Jacobian matrix of the articulation body hierarchy. |
| ArticulationReducedSpace | Coordinates in reduced space. |
| BoxcastCommand | Use this struct to set up a box cast command to be performed asynchronously during a job. |
| BoxGeometry | Contains the basic geometric shape of a box. |
| CapsulecastCommand | Use this struct to set up a capsule cast command that is performed asynchronously during a job. |
| CapsuleGeometry | Contains the basic geometric shape of a capsule. |
| ClosestPointCommand | Struct used to set up a closest point command to be performed asynchronously during a job. |
| ColliderHit | Struct used to retrieve information from an Overlap batch query. |
| ContactPair | A pair of Colliders that belong to the bodies in the parent ContactPairHeader struct. |
| ContactPairHeader | A header struct which contains colliding bodies. |
| ContactPairPoint | A readonly struct describing a contact point between two Colliders. |
| ContactPoint | Describes a contact point where the collision occurs. |
| ConvexMeshGeometry | Contains the basic geometric shape of a convex mesh. |
| GeometryHolder | Holds the basic information of a geometric shape and its type. |
| ImmediateContact | Describes a contact where two shapes collide. |
| ImmediateTransform | A transform, containing a position and rotation. |
| JointDrive | How the joint's movement will behave along its local X axis. |
| JointLimits | JointLimits is used by the HingeJoint to limit the joints angle. |
| JointMotor | The JointMotor is used to motorize a joint. |
| JointSpring | JointSpring is used add a spring force to HingeJoint and PhysicsMaterial. |
| ModifiableContactPair | A light-weight proxy that allows to access the contact buffers directly. |
| ModifiableMassProperties | Mass-related modifiable properties of a contact pair. |
| OverlapBoxCommand | Struct used to set up an overlap box command to be performed asynchronously during a job. |
| OverlapCapsuleCommand | Struct used to set up an overlap capsule command to be performed asynchronously during a job. |
| OverlapSphereCommand | Struct used to setup an overlap sphere command to be performed asynchronously during a job. |
| PhysicsScene | Represents a single instance of a 3D physics Scene. |
| PhysicsSceneLoadScope | Scope used during scene load operations such as SceneManager.LoadSceneAsync, with the purpose of providing a different physics scene than the global one. |
| QueryParameters | Creates a struct to set up parameters for batch queries: RaycastCommand, BoxcastCommand, CapsulecastCommand, SpherecastCommand. |
| RaycastCommand | Struct used to set up a raycast command to be performed asynchronously during a job. |
| RaycastHit | Structure used to get information back from a raycast. |
| SoftJointLimit | The limits defined by the CharacterJoint. |
| SoftJointLimitSpring | The configuration of the spring attached to the joint's limits: linear and angular. Used by CharacterJoint and ConfigurableJoint. |
| SpherecastCommand | Use this struct to set up a sphere cast command that is performed asynchronously during a job. |
| SphereGeometry | Contains the basic geometric shape of a sphere. |
| TerrainGeometry | Contains the geometric shape of a Terrain collider. |
| TriangleMeshGeometry | Contains the basic geometric shape of a non-convex mesh (sometimes known as a triangle mesh). |
| WheelFrictionCurve | WheelFrictionCurve is used by the WheelCollider to describe friction properties of the wheel tire. |
Enums
Enum | Description |
|---|---|
| ArticulationDofLock | The lock type applied to a particular degree of freedom of an articulation body. |
| ArticulationDriveAxis | An axis of a drive of an ArticulationBody. |
| ArticulationDriveType | The drive type applied to a particular drive of an ArticulationBody. |
| ArticulationJointType | The type of the joint that restricts movement of the two connected articulation bodies. |
| CollisionDetectionMode | The collision detection mode constants used for Rigidbody.collisionDetectionMode. |
| CollisionFlags | CollisionFlags is a bitmask returned by CharacterController.Move. |
| ConfigurableJointMotion | Constrains movement for a ConfigurableJoint along the 6 axes. |
| ForceMode | Use ForceMode to specify how to apply a force using Rigidbody.AddForce or ArticulationBody.AddForce. |
| GeometryType | The set of basic geometry shape types that can exist. |
| JointProjectionMode | Determines how to snap physics joints back to its constrained position when it drifts off too much. |
| MeshColliderCookingOptions | Cooking options that are available with MeshCollider. |
| PhysicsMaterialCombine | Describes how physics materials of the colliding objects are combined. |
| QueryTriggerInteraction | Overrides the global Physics.queriesHitTriggers. |
| RigidbodyConstraints | Use these flags to constrain motion of Rigidbodies. |
| RigidbodyInterpolation | Rigidbody interpolation mode. |
| RotationDriveMode | Control ConfigurableJoint's rotation with either X & YZ or Slerp Drive. |
| SimulationMode | A selection of modes that control when Unity executes the physics simulation. |
| SimulationOption | An enumerator that specifies physics simulation options. |
| SimulationStage | A flag enum to determine which simulation stages to run. |
Interfaces
Interface | Description |
|---|---|
| IGeometry | All basic geometric shapes implement this interface. |