Physics · interface
Executor
Explained in Your first game, Rigid bodies.
interface Executorimport type { Executor } from '@driftengine/physics';Properties
| Name | Type | Description |
|---|---|---|
namereadonly | string | A name, so a figure taken from a benchmark says which character produced it. |
failurereadonlyoptional | string | null | Set once a character has given up and gone serial, with a sentence saying why. Null while healthy. |
Methods
run
run(count: number, solver: IslandSolver): void| Parameter | Type | Description |
|---|---|---|
count | number | |
solver | IslandSolver |
disposeoptional
dispose?(): voidRelease whatever the character holds. A pool terminates its workers.
More
Optional, and declared here rather than tested for with instanceof, because reaching the pool
class from world.ts would put the whole pool in every consumer's bundle — including the ones
that never ask for a worker. Measured at 2,629 bytes gzipped, which is the difference between
this seam being a seam and being a static dependency.