Correct scene model light intensity

This commit is contained in:
Pascal Serrarens 2024-12-09 17:06:27 +01:00
parent 173c08454b
commit ef007dd9e8

View File

@ -546,6 +546,11 @@ namespace Passer.Humanoid {
loadingModel = false;
Transform parentTransform = await InstantiateGltf(gltfImport, msg.thingId, msg.scale);
ScanModelForThings(parentTransform);
// Correct lights
Light[] lights = parentTransform.GetComponentsInChildren<Light>();
foreach (Light light in lights)
light.intensity = 1; // light.intensity / 1000;
}
else {
this.transform.localScale = Vector3.one * 1;