Talos docs

light

Since 0.6Changed in next
Plain text

Use it in a scene entity's components list as { "type": "light", … }. The contract writes the fields flat and refuses unknown keys.

Fields

FieldTypeRequiredDefaultAllowed valuesDescription
kindLightKindyesdirectional, point, spot
colorstringyes
intensitynumberyes
castShadowbooleanno
rangenumberno
anglenumberno
shadowTintLightShadowTintnoDirectional lights only (light-shadow-tint-ignored on any other kind). Lifts the sun's shadows: a shadowed surface receives strength of the sun's light in color, scaled by the surface's albedo and its angle to the sun, on top of the sky light, so shadows on a dark surface stop going black. Absent changes nothing (the image is byte-identical). Standard renderer's lit materials only (pbr, toon, vertex); the HD renderer, custom shaders and unlit materials ignore it. strength outside 0..1 or a color that is not a hex colour is light-shadow-tint-range.
indirectIntensitynumbernoMultiplier on this light's contribution to the indirect (bounced) light, 0..16; absent means no change. Zero keeps the light's direct light and removes its bounce; two doubles the bounce. HD's ray-traced GI only: the standard renderer ignores it (hd-only-ignored). Changing it while the scene runs re-lights the GI within a few frames, with no restart.

Rules that can refuse it

Example

From the contract's tested fixture fixtures/contract/full20/scene.json#lamps.

{
  "type": "light",
  "kind": "point",
  "color": "#FFD9A0",
  "intensity": 12,
  "range": 9
}