Skip to content

Commit 58714c2

Browse files
Fix lights correctly hidden at start
1 parent 1206fbb commit 58714c2

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

‎extensions/reviewed/Light3D.json‎

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -598,7 +598,11 @@
598598
" spotLight.castShadow = false;",
599599
" spotLight.visible = false;",
600600
"",
601-
" if (!object.isHidden()) {",
601+
" // Instances hidden at start stay visible in the editor, but their light must not shine.",
602+
" const isHiddenAtStartInEditor =",
603+
" !!editor && !!editor.isInstanceHiddenAtStart && editor.isInstanceHiddenAtStart(object);",
604+
"",
605+
" if (!object.isHidden() && !isHiddenAtStartInEditor) {",
602606
" let isSelected = false;",
603607
" if (editor) {",
604608
" const selectedObject = editor._selection.getLastSelectedObject();",

0 commit comments

Comments
 (0)