Log inGet started
World

Builtin Library

Branchmain
Branchesmainpublish
Commitdd348ac6c3

README.md

shared Module

Cross-tool resolution + introspection engine for the lighting toolbox. Every tool inside this toolbox pulls these in with require(".shared").

Purpose

Tools have unlimited perf budget — full entity scans and per-candidate asset reads live here, never in modules/. This module owns: finding the scene's sky entity, resolving a word to a sky material by shader domain (@domain: sky in the shader's WGSL header — the name finds, the shader decides), reading and writing a material's editable parameters, and resolving a light by name (exact, then substring, with an ambiguity error that lists every candidate).

Usage

local shared = require(".shared")

local found = shared.findSkyEntity()
local pick, alternatives = shared.resolveSkyMaterial("sunset")
local target = shared.resolveLight("torch1")

Exports

See init.luau for the full export surface: normalizeColor, vec3, findSkyEntity, ensureSkyComponent, isSkyMaterial, listSkyMaterials, resolveSkyMaterial, materialParams, applySkyMaterialParams, listLightEntities, resolveLight.