OcclusionProxy
A coarse stand-in for an entity's bulk, so it darkens the ground under and around itself.
OcclusionProxy
A coarse stand-in for an entity's bulk, so it darkens the ground under and around itself.
local id = entity.spawn("boulder").id
entity(id).component.add("OcclusionProxy", {
radius = 2.0,
height = 3.0, -- 0 gives a sphere
})
Put it on a character and the character grounds itself; put it on a boulder and the boulder shades the dirt beside it — without a shadow view, and at any distance. A subject well past the sun's cascade range still gets this, which is the difference between standing on a surface and floating over it.
The proxy follows its entity every frame, so a moving subject keeps its grounding with no popping.
Every field is live: edit one in the inspector and the proxy follows. A
radius of 0 removes it without losing the rest of the settings.
The capsule's axis runs along world up. A capsule that tilted with its entity would need the entity's rotation resolved every frame for a shape whose whole job is to be approximate.
For code placing proxies directly, reach for
@builtin::systems.proxyOcclusion.proxyOcclusion — same shapes, no component.
The full description is in the package readme:
guides { path = "systems/proxyOcclusion" }.
Interface
What this asset declares: the schema it conforms to, what it exposes, and the rendered structured payload.
conforms to
zero/source-extract/v2OcclusionProxy Component A coarse stand-in for this entity's bulk, so it darkens the ground under and around itself. Put it on a character and the character grounds itself; put it on a boulder and the boulder shades the dirt beside it — without a shadow view, and at any distance. The proxy is a capsule in the entity's own space, so it follows the entity every frame. A subject well past the sun's cascade range still gets this, which is the difference between standing on a surface and floating over it. The fields ARE the proxy — editing one in the inspector re-pushes it, and the values persist with the scene like any other component. The work runs in `proxyOcclusion.renderFeature`, driven through `@builtin::systems.proxyOcclusion.proxyOcclusion`. Usage: local id = entity.spawn("boulder").id entity(id).component.add("OcclusionProxy", { radius = 2.0, height = 3.0, })
push( ) → void
awake( ) → void
update(_dt: ?) → void
| arg | type | description |
|---|---|---|
| _dt | ? |
editorUpdate(_dt: ?) → void
| arg | type | description |
|---|---|---|
| _dt | ? |
onDestroy( ) → void
Sub-parts
Everything contained inside this part. Assets are composite children (clickable cards). Files are leaf payloads. Expand any row to view its source.
Problems
Everything affecting this asset right now: its own problems, anything wrong inside it, and problems on its direct dependencies.
agent_score is exposed.+ 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".
Scoped to this part · feeds back into the world's score.