UNITY 3D PHYSICS, COLLISIONS & FORCES HUB

A complete engineering blueprint for rigid bodies, spatial collision detection, contact physics, friction materials, and collision matrix performance in Unity.

The PhysX Engine in Unity

Unity incorporates the NVIDIA PhysX physics engine to simulate realistic acceleration, gravity, contact friction, restitution (bounciness), and rotational torque. Understanding how PhysX evaluates contacts during the discrete fixed timestep (FixedUpdate at 50Hz by default) is essential to prevent game-breaking glitches such as high-speed tunneling, vibrating objects, and physics CPU spikes on mobile hardware.

Collision Matrix Pruning
Broadphase collision checking scales with $O(N^2)$ if all layers collide. Unchecking unneeded layer pairs in Project Settings > Physics cuts physics CPU time by up to 60%.
Continuous Collision Detection (CCD)
Fast-moving projectiles penetrate thin walls in Discrete mode. Switching fast objects to ContinuousDynamic sweeps shapes to guarantee contact detection.
Physic Material Restitution
Control kinetic energy transfer with dynamic/static friction and bounce combine modes (Average, Minimum, Multiply, Maximum).

Guides in This Cluster

Complete breakdown of ForceMode.Force, Impulse, VelocityChange, Acceleration, center of mass, angular drag, and Rigidbody interpolation.

Primitive collider performance advantages, convex mesh limits (255 triangles), compound colliders, and dynamic vs static collider rules.

Differences between OnCollisionEnter and OnTriggerEnter, contact point generation overhead, trigger zones for pickups, checkpoints, and sensor areas.

How to create realistic icy tracks, bouncy rubber projectiles, grippy asphalt, and configure friction combination formulas without micro-glitches.

Master layer bitmasks, Physics.Raycast layer filters, and clean architecture for multi-faction games (Player, Enemy, PlayerProjectile, EnemyProjectile, Debris).

Simulate forward aircraft velocity inheritance, quadratic air drag, terminal velocity, and explosion radial damage with Physics.OverlapSphere.

Companion Tools & Error Troubleshooting

Physics Hub FAQ

A GameObject with a Collider but no Rigidbody is classified as a Static Collider. PhysX bakes static colliders into a spatial acceleration BVH tree. Moving a static collider forces PhysX to rebuild the entire spatial tree, creating major frame spikes. If a collider must move, always attach a Rigidbody and set isKinematic = true.
In discrete collision detection, Unity checks positions at instantaneous time steps (e.g. 0.02s). If a bullet travels 2 meters per step and the wall is 0.2 meters thick, the bullet's step can jump completely from before the wall to behind it. Solve this with Continuous Dynamic collision mode or Raycast sweep checks.