SLight

Index

Properties Index

Property Name

bool Enabled get set

float Range get set

float SpotAngle get set

float Intensity get set

SVector Color get set

SLightType Type get set

SGameObject GameObject get

Properties

Enabled

bool Enabled get set

Enable/Disable this light.

Space.Host.ExecutingObject.Light.Enabled = false
--the below script will make the object Enable/Disable it's Light component
--[Add "light" reference to the Scripting Runtime component]

thisGameObject = Space.Host.ExecutingObject
light = Space.Host.GetReference("light").Light


OnClick = function()
light.Enabled =  not light.Enabled
end


thisGameObject.AddClickable()
thisGameObject.Clickable.OnClick(OnClick)

Range

float Range get set

Get/Set the effective range of the light source.

SpotAngle

float SpotAngle get set

The angle of the light's spotlight cone in degrees.

Intensity

float Intensity get set

Property Description

Color

SVector Color get set

Get/Set the color of the light.

Type

int Type get set

Get/Set the type of light this source is. 0 = Directional, 1 = Point, 2 = Spot, 3 = Area.

GameObject

SGameObject GameObject get

Property Description

Last updated

Was this helpful?