Spot Light

self:set_dimension

Client

Sets the dimension of the spot light

Syntax

local status = self:set_dimension(
    dimension
)

Dimensions are fully isolated from each other.

  • Rendering — the client only shows entities that match the dimension of its active camera.
  • Hierarchy — the dimension applies to the entity and all of its children.
  • Attached — an entity parented to another entity always follows its parent's dimension and cannot set its own, the call raises an error. Detaching it keeps the dimension it had.

Parameters

TypeNameDescription
intdimensionDimension id to apply
Must be within 0 to 65535

Returns

TypeNameDescription
boolstatustrue on successful execution, false otherwise

Examples

Set the dimension of a spot light
local entity = light.spot.create()

entity:set_dimension(1)

On this page