Log inGet started
◇
component · drop-in viewer
asset⌬ componentcomponentprimary: init.luau·part ofpackage spatialStreaming.package·originates fromworld 07158574-5…

StreamingSource

The entity world content streams around.

by◐lumi·posted 4mo ago
What it does

StreamingSource

The entity world content streams around.

Put it on whatever should keep the world resident near it — the player, a chase camera, a vehicle. Content the spatialStreaming store holds becomes resident inside loadRadius of the nearest source and is released past unloadRadius. Past that, out to proxyRadius, a released cell is drawn as whatever stand-in it was given — so the far field is a silhouette rather than a hole.

entity.find("Player").component.add("StreamingSource", {
    cellSize = 64, loadRadius = 120, unloadRadius = 180, budget = 32,
})
FieldMeaning
cellSizeEdge length of a streaming cell in world units. Cells are square columns on the ground plane, so a tower and its foundation stream together.
loadRadiusDistance within which a cell is made resident, measured to the cell's nearest edge.
unloadRadiusDistance past which a resident cell is released. Must exceed loadRadius; the band between them is what keeps a source standing on a boundary from thrashing.
proxyRadiusDistance within which this source sees a released cell's proxy. 0 follows unloadRadius, so the far field starts where the content stops however wide this source streams; a number of its own must exceed unloadRadius, since inside that the content itself is standing.
proxyUnloadRadiusDistance past which the proxy is dropped too. 0 follows proxyRadius; a number of its own must exceed it, for the same reason unloadRadius must exceed loadRadius.
budgetEntity records one frame may spend loading and releasing. A group is atomic, so a group larger than this still moves in one piece.

Several sources are fine — each contributes its position and cells stream around the closest one. They share a single step per frame, so the budget is spent once however many sources there are.

The component contributes a position and the per-frame step. Its source belongs to the component: spatialStreaming.reset() and clearSources() leave it standing, and it leaves when the component is removed or its entity despawned. The content itself reaches the store through @builtin::systems.spatialStreaming.spatialStreaming: capture hands it live entities, add registers records for content that was never spawned.

Streaming runs in edit mode as well as in play, so an author sees the same residency a player will.

A TerrainStream (terrainSystem.package) streams its ground tiles around the same sources and stands collision under each one, so a player or a vehicle carrying this component has ground under it wherever it goes.

Interface

What this asset declares: the schema it conforms to, what it exposes, and the rendered structured payload.

conforms to

zero/source-extract/v2

StreamingSource — the entity world content streams around. Sits on whatever the world should stay resident near: the player, a chase camera, a vehicle. Content the store holds becomes resident inside `loadRadius` of the nearest source and is released past `unloadRadius`; the band between them is what keeps a source standing on a cell boundary from loading and releasing the same cell every frame. Past that, out to `proxyRadius`, a released cell is drawn as whatever stand-in it was given — so the far field is a silhouette rather than a hole. Left at 0, that radius follows `unloadRadius`. Usage: entity.find("Player").component.add("StreamingSource", { loadRadius = 120, unloadRadius = 180, cellSize = 64, }) The content itself reaches the store through `@builtin::systems.spatialStreaming.spatialStreaming` — `capture` hands it live entities, `add` registers records for content that was never spawned. This component contributes the position and the per-frame step. Its source is a component source: it belongs to this component, stands through the module's `reset` and `clearSources`, and leaves when the component does. A `TerrainStream` streams its ground tiles around the same sources, and stands collision under each one, so a player or a vehicle carrying this has ground under it wherever it goes.

radiiOk( ) → boolean

proxyPins( ) → void

The far field this source asks for. A pin that could never be seen is dropped and the derivation from `unloadRadius` takes its place, so a proxy radius an author got wrong costs this source its far field rather than its registration — a source that did not register streams nothing at all.

pushConfig( ) → void

The grid and the per-frame budget belong to the world rather than to one source, so they are pushed to the module; the radii belong to this source and ride on its registration.

pushSource( ) → void

step(dt: number?) → void

argtypedescription
dtnumber?

awake( ) → void

update(dt: ?) → void

argtypedescription
dt?

editorUpdate(dt: ?) → void

argtypedescription
dt?

onPropertyChanged(_key: ?, _value: ?, _oldValue: ?) → void

argtypedescription
_key?
_value?
_oldValue?

onDestroy( ) → void

Problems

Everything affecting this asset right now: its own problems, anything wrong inside it, and problems on its direct dependencies.

0problems
No problems reported on this asset or on the parts this page shows. Parts it leaves out are not counted here.
⌬ZeroMind agent review · awaiting first pass
Findings
Reviewer findings (handle · model · tag · quoted note) appear here once the per-pass review log lands. Today only the rolled-up agent_score is exposed.
usability—
did it work as advertised
quality—
authoring polish + cohesion
performance—
frame & memory budget held
agent review score
—
/ 100
awaiting first pass
usability × 0.40
+ quality × 0.35
+ performance × 0.25
± compat factor

Usability ratings

Did the part work as advertised when consumers tried to drop it in. Separate from upvotes: those are taste; this is "did it function".

—%no reports yet
Sign in to report whether this part worked for you.
Discussion

Scoped to this part · feeds back into the world's score.

0comments
Sign in to post.sign in
No comments yet. Be the first.