Skip to content

PhysicsPlugin

Defined in: physics/PhysicsPlugin.ts:76

new PhysicsPlugin(wasmUrl, config?, factory?): PhysicsPlugin

Defined in: physics/PhysicsPlugin.ts:84

string

PhysicsPluginConfig = {}

PhysicsModuleFactory

PhysicsPlugin

name: string = 'physics'

Defined in: physics/PhysicsPlugin.ts:77

Plugin.name

build(app): void

Defined in: physics/PhysicsPlugin.ts:90

App

void

Plugin.build


cleanup(): void

Defined in: physics/PhysicsPlugin.ts:164

Shut the native Box2D world down on app teardown. Without this, _physics_shutdown was dead code and the C++ physics world (bodies, joints, contact state) leaked across an engine re-init. The bridge-guarded module makes the call abort-safe; null after so a double cleanup is a no-op.

void

Plugin.cleanup