Skip to content

WorldProps

Defined in: packages/engine/src/components/World.tsx:32

  • PropsWithChildren
Property Type Default value Description
children? ReactNode undefined -
dayLengthSeconds? number 1200 Real seconds a whole day-night cycle takes. The engine’s own when left out. Anything but a finite number above zero logs a warning, and the clock keeps its last valid length, which on mount is the default.
gravity? number 9.8 Metres a second squared, pulled on every falling actor and dynamic body.
look? LookPick undefined A named look: the sky its models light from, fog, exposure, grading and a post-processing stack, which picking one opts in to. A name, or { name, ...values } to override any of its values.
map string undefined The name of a registered map.
navmesh? boolean false Draws the navmesh’s wireframe.
scatter? number 1 The share of the decorative scatter to stand, 0 to 1: what blocks always stands; this thins what only decorates. A weak device may draw less grass, and a player still meets every rock and tree the room and every other player meet.
shadowMapSize? number 1024 The side of the sun’s shadow map in texels; 0 casts none.
startHour? number 10 The hour this World opens on. The look’s, or the engine’s own, when left out.