@@ -52,10 +52,10 @@ <h2>Example</h2>
5252 </ p >
5353
5454 < code >
55- // White directional light at half intensity shining from the top.
56- var directionalLight = new THREE.DirectionalLight( 0xffffff, 0.5 );
57- scene.add( directionalLight );
58- </ code >
55+ // White directional light at half intensity shining from the top.
56+ var directionalLight = new THREE.DirectionalLight( 0xffffff, 0.5 );
57+ scene.add( directionalLight );
58+ </ code >
5959
6060
6161 < h2 > Constructor</ h2 >
@@ -104,26 +104,28 @@ <h3>[property:Object3D target]</h3>
104104
105105 *Note*: For the target's position to be changed to anything other than the default,
106106 it must be added to the [page:Scene scene] using
107- < code >
108- scene.add( light.target );
109- </ code >
110-
107+ </ p >
108+ < code >
109+ scene.add( light.target );
110+ </ code >
111+ < p >
111112 This is so that the target's [page:Object3D.matrixWorld matrixWorld] gets automatically
112113 updated each frame.< br /> < br />
113114
114115 It is also possible to set the target to be another object in the scene (anything with a
115116 [page:Object3D.position position] property), like so:
116- < code >
117- var targetObject = new THREE.Object3D();
118- scene.add(targetObject);
117+ </ p >
118+ < code >
119+ var targetObject = new THREE.Object3D();
120+ scene.add(targetObject);
119121
120- light.target = targetObject;
121- </ code >
122+ light.target = targetObject;
123+ </ code >
124+ < p >
122125 The directionalLight will now track the target object.
123126 </ p >
124127
125128
126-
127129 < h2 > Methods</ h2 >
128130
129131 See the base [page:Light Light] class for common methods.
0 commit comments