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

ObstaclesTrait

const ObstaclesTrait: Trait<{ bake: () => ObstacleBake | null; }>

What of the scatter the character cannot walk through, baked by bakeGroundObstacles from the scatter shapes table when the ground is dressed. bake is null where nothing blocks; the trait’s presence is what says the bake has run. In a room’s world the ready tree is built at its first query, since nothing in a room need query it: that query pays the build, which takes 316 MB of heap on the 1.5 km forest.