diff --git a/src/document/scene-document-validation.ts b/src/document/scene-document-validation.ts index 8642cb96..9b7359ca 100644 --- a/src/document/scene-document-validation.ts +++ b/src/document/scene-document-validation.ts @@ -148,6 +148,17 @@ function validateWorldSettings(world: WorldSettings, document: SceneDocument, di ); } } + + if (!isNonNegativeFiniteNumber(world.background.environmentIntensity)) { + diagnostics.push( + createDiagnostic( + "error", + "invalid-world-background-environment-intensity", + "World background environment intensity must be a non-negative finite number.", + "world.background.environmentIntensity" + ) + ); + } } if (!isHexColorString(world.ambientLight.colorHex)) {