# PhysicsWorld

Class · category: Physics

Source: https://github.com/playcanvas/engine/blob/f059dc005842f76e052cdf44d8370c8c7ec475ac/src/framework/physics/physics-world.js#L171

The base class for physics backends. A PhysicsWorld owns the lifecycle of a physics engine's
simulation world: stepping, gravity, body and shape factories, joints, raycasts and contact
reporting. Backends subclass it and override every method.

The base implementation is a functional no-op: bodies and joints are created but inert,
raycasts miss and stepping does nothing. [NullPhysicsWorld](https://api.playcanvas.com/engine/classes/NullPhysicsWorld.md) uses this to let physics
component lifecycle run without a physics engine loaded.

Supply a backend to an application with [AppOptions#physicsWorld](https://api.playcanvas.com/engine/classes/AppOptions.md#physicsworld).

Applications drive physics through the physics components - the methods of this class form
the internal contract between the engine and a backend and are not called directly.

## Constructors

### constructor

```ts
new PhysicsWorld()
```

## Properties

### nativeWorld

```ts
nativeWorld: any = null
```

The backend-native world object - btDiscreteDynamicsWorld when the Ammo backend is
active, null otherwise.
