Constructors
constructor
- new ColliderSet(raw?: RawColliderSet): ColliderSet
-
Parameters
-
Optional
raw: RawColliderSet
Properties
Private
map
map: any
raw
raw: RawColliderSet
Methods
castClosure
- castClosure<Res>(f?: ((collider: Collider) => Res)): ((handle: number) => Res)
Internal
Parameters
-
Optional
f: ((collider: Collider) => Res)
Returns ((handle: number) => Res)
-
- (handle: number): Res
Internal
Returns Res
contains
- contains(handle: number): boolean
-
Returns boolean
finalizeDeserialization
- finalizeDeserialization(bodies: RigidBodySet): void
Internal
Returns void
forEach
- forEach(f: ((collider: Collider) => void)): void
-
Returns void
free
- free(): void
-
Returns void
get
- get(handle: number): Collider
-
getAll
- getAll(): Collider[]
-
len
- len(): number
-
Returns number
remove
- remove(handle: number, islands: IslandManager, bodies: RigidBodySet, wakeUp: boolean): void
-
Parameters
-
handle: number
-
-
-
wakeUp: boolean
Returns void
unmap
- unmap(handle: number): void
-
Returns void
A set of rigid bodies that can be handled by a physics pipeline.
To avoid leaking WASM resources, this MUST be freed manually with
colliderSet.free()
once you are done using it (and all the rigid-bodies it created).