Skip to content

@temporary-escape/mod-sdk / SpawnCallback

Type Alias: SpawnCallback ​

ts
type SpawnCallback = (entity: Entity, args: SpawnArgsView) => void;

Defined in: templates.ts:55

Typed template hooks. The builder stores the callback, and a single plain trampoline per hook kind dispatches to it using the slot the host passes back. AssemblyScript 0.28.20 does not implement closures, so callbacks must be module-level functions (or methods whose receiver is not captured).

Parameters ​

ParameterType
entityEntity
argsSpawnArgsView

Returns ​

void