Skip to content

five-on-it / packages/world/src/scents

packages/world/src/scents ​

What a dog stops to sniff at: the level's street furniture and its plants (a lamp post, a traffic light, a hydrant, a bin, a bench, a mailbox, a sign, a tree, a bush), each where its placement stands. They are not authored: a placement is one by its mesh key (isScentMesh), so every level that plants a tree has it. Sorted into a grid of SCENT_CELL m once per level object, the same on the server and every client; the simulation's dogs ask for the nearest one (nearestScent). Pure and deterministic.

Interfaces ​

Variables ​

Functions ​