Forge2DWorld constructor

Forge2DWorld({
  1. Vector2? gravity,
  2. ContactListener? contactListener,
  3. Iterable<Component>? children,
})

Implementation

Forge2DWorld({
  Vector2? gravity,
  forge2d.ContactListener? contactListener,
  super.children,
}) : physicsWorld = forge2d.World(gravity ?? defaultGravity)
        ..setContactListener(contactListener ?? WorldContactListener());