Skip to content

1681-engine / index / Shape

Type Alias: Shape ​

ts
type Shape = 
  | CircleShape
  | BoxShape
  | PolygonShape;

Defined in: src/physics/types.ts:8

The shapes a body may have, each centred on the body's position. A body turns only when it is made with rotates: true; a platformer's bodies need no rotation, and a body that never turns keeps the cheap axis-aligned tests and the steadiest stacks.

Released under the MIT License.