DriftScript bindings · function

assertHostShapes

Check every from host declaration against what the host registered.

Explained in Setting up scripts.

function assertHostShapes(module: DriftModule, registry: ComponentRegistry): void
import { assertHostShapes } from '@driftengine/script';

Parameters

ParameterTypeDescription
moduleDriftModule
registryComponentRegistry

In depth

Throws on the first mismatch rather than collecting: a shape disagreement means the module was compiled against a different world than the one it is being loaded into, and the second error would be a consequence of the first.