Skip to content

Components

Occluder

A shape that blocks light, casting a shadow away from every Light that reaches it. A box by default, with an optional outline so the shadow is not just a rectangle around the real shape.

On this page

Add it

+ Add node → Occluder creates a node with it already on. Already have a node for it? Add component → OccluderComponent.

From a script

A script on the same node writes these fields by name. OccluderComponent is the name to pass.

rgs
set_flag("OccluderComponent", "enabled", true);
set_point("OccluderComponent", "size", vec2(64.0, 64.0));

Fields

FieldScript nameKindDefaultWhat it does
EnabledenabledcheckboxonWhether this blocks light.
Sizesizetwo numbers (x, y), at least 0(64, 64)Size in world units, centred on the node.
OutlinepointslistemptyShape that casts, in place of the box; three points or more.