Skip to content

Commit 2b7c115

Browse files
committed
Fixed shadows in cars demo.
Bah, this one was tricky. World positions are not updated for objects that are not part of the scene graph so spotlight target was just hanging in limbo.
1 parent 9fdd141 commit 2b7c115

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

examples/webgl_materials_cubemap_dynamic.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,7 @@
178178
spotLight.shadowMapHeight = SHADOW_MAP_HEIGHT;
179179

180180
scene.add( spotLight );
181+
scene.add( spotLight.target );
181182

182183
directionalLight2 = new THREE.PointLight( 0xff9900, 0.25 );
183184
directionalLight2.position.set( 0.5, -1, 0.5 );

0 commit comments

Comments
 (0)