Skip to main content

LightingManager

This item only works when running on the client. Client

Manager module responsible for the functionality of Lighting Changers and other things generally related to lighting.

Functions

ChangeLighting

LightingManager:ChangeLighting(config_TDefs.LightingConfiguration) → ()

Types

interface LightingConfiguration {
Typestring
ConfigurationDefault | {[string]any}
TweenInfoTweenInfo?
UseDefaultstring?
SetDefaultstring?
}

Changes the active lighting based on the given config. You can create a lighting preset by using SetDefault as a string parameter in a lighting changer's config module. These can then be reused by using UseDefault as a string parameter with the same value.

ResetLighting

LightingManager:ResetLighting() → ()

Resets all lighting properties back to their default state.

DeregisterPreset

LightingManager:DeregisterPreset(presetstring) → ()

Removes the registered preset from the lighting template list. Used when the client object folder unloads.

Show raw api
{
    "functions": [
        {
            "name": "ChangeLighting",
            "desc": "Changes the active lighting based on the given `config`.\nYou can create a lighting preset by using `SetDefault` as a `string` parameter in a\nlighting changer's config module. These can then be reused by using `UseDefault`\nas a `string` parameter with the same value.",
            "params": [
                {
                    "name": "config",
                    "desc": "",
                    "lua_type": "_TDefs.LightingConfiguration"
                }
            ],
            "returns": [],
            "function_type": "method",
            "source": {
                "line": 119,
                "path": "mirror/Kit.Managers.LightingManager.luau"
            }
        },
        {
            "name": "ResetLighting",
            "desc": "Resets all lighting properties back to their default state.",
            "params": [],
            "returns": [],
            "function_type": "method",
            "source": {
                "line": 177,
                "path": "mirror/Kit.Managers.LightingManager.luau"
            }
        },
        {
            "name": "DeregisterPreset",
            "desc": "Removes the registered `preset` from the lighting template list.\nUsed when the client object folder unloads.",
            "params": [
                {
                    "name": "preset",
                    "desc": "",
                    "lua_type": "string"
                }
            ],
            "returns": [],
            "function_type": "method",
            "source": {
                "line": 192,
                "path": "mirror/Kit.Managers.LightingManager.luau"
            }
        }
    ],
    "properties": [],
    "types": [
        {
            "name": "LightingConfiguration",
            "desc": "",
            "fields": [
                {
                    "name": "Type",
                    "lua_type": "string",
                    "desc": ""
                },
                {
                    "name": "Configuration",
                    "lua_type": "Default | { [string]: any }",
                    "desc": ""
                },
                {
                    "name": "TweenInfo",
                    "lua_type": "TweenInfo?",
                    "desc": ""
                },
                {
                    "name": "UseDefault",
                    "lua_type": "string?",
                    "desc": ""
                },
                {
                    "name": "SetDefault",
                    "lua_type": "string?",
                    "desc": ""
                }
            ],
            "source": {
                "line": 16,
                "path": "mirror/Kit.Managers.LightingManager.TypeDefs.luau"
            }
        }
    ],
    "name": "LightingManager",
    "desc": "Manager module responsible for the functionality of Lighting Changers\nand other things generally related to lighting.",
    "realm": [
        "Client"
    ],
    "source": {
        "line": 14,
        "path": "mirror/Kit.Managers.LightingManager.luau"
    }
}