Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


Configuring LowLevelPhysics2D API scenes

Configure 2D physics objects and global settings, and attach custom data to physics objects.
Read time 1 minuteLast updated 13 days ago

Configure properties such as gravity, friction, position, and shape on a world, body, or shape using the
LowLevelPhysics2D
API.
Note
This documentation is about writing C# scripts using the
LowLevelPhysics2D
API. To use 2D physics in the Unity Editor using components like the Rigidbody 2D component, refer to 2D physics instead.

Topic

Description

Configure objects with definitionsCreate a definition object to configure properties such as gravity, friction, position, and shape.
Configure global LowLevelPhysics2D API settingsTo configure layers, default definition values, and global settings, create and assign a Physics Low Level Settings 2D asset.
Attach custom data to objectsAttach values and physics masks to physics objects so you can fetch them later.

Additional resources