M MY Multiplayer: Wiki
Side
Kind

setLightFalloff

Client

Changes how a light fades toward the end of its range.

bool setLightFalloff(light light, float falloff)

Parameters

NameTypeDescription
lightlightThe light.
fallofffloatExponent of the fade toward the radius, from 0.1 to 32. Higher values keep the light strong closer to its edge.

Returns

true if it changed. With a wrong argument it logs a warning and returns false.

A new light starts at 4.

Example

local light = createPointLight(2495.1, -1687.4, 14.5, 15)
setLightFalloff(light, 1)

See also