Skip to content
Work in progress. These docs describe Spawnite at launch, and some parts are still being built.

InteractTrait

const InteractTrait: Trait<{ distanceTolerance: number; exclusive: boolean; near: boolean; prompt: string; radius: number; targets: () => TargetFilter; }>

near while any of its targets has a body within the sphere of radius about the entity. The callback stays on the Interact component, which fires it: a stream carries no function.