Ara
Download

Search or run a command

Jump to a section or open an Ara link.

Component · render

Light

A light at the entity's world position. Edits apply live in play.

Fields

Point, spot or directional.
default "point"

One ofpointspotdirectional

color

color
Linear RGB tint (alpha is ignored).
default [1,1,1,1]

intensity

f32
Luminous flux in lumens (point/spot) or illuminance in lux (directional).
default 800≥ 0

range

f32
Influence radius of point and spot lights.
default 10m≥ 0.01shown when kind is point or spot

innerAngle

f32
Spot inner cone half-angle.
default 20deg0 – 89shown when kind is spot

outerAngle

f32
Spot outer cone half-angle.
default 30deg0.1 – 89shown when kind is spot

Usage

Every edit is an undoable command: from the CLI as below, or the same JSON from an agent over MCP. See component.add and property.set.

Add it

ara do component.add -p entity=name:Crate -p component=Light --why "Add Light"

Set a field

ara do property.set -p entity=name:Crate -p path=Light.kind -p value="point" --why "Tune Light"

In a scene document

{
  "Light": {
    "kind": "point"
  }
}

From C#

/// <summary>Flicker a lamp using fixed tick time, without wall-clock randomness.</summary>
public static void UseLight(Entity entity, in Tick tick)
{
    ref var component = ref World.Get<Light>(entity);
    component.Intensity = tick.Frame % 4 == 0 ? 450f : 500f;
}

From C#

Scripts read and write it with Get<Light>(); see the Light struct.