diff --git a/docs/manual/introduction/How-to-update-things.html b/docs/manual/introduction/How-to-update-things.html index b937c2fd18670db44ccbc69247af06f80f88e2df..70bac0dad5deea926d19b4711f419442902a7659 100644 --- a/docs/manual/introduction/How-to-update-things.html +++ b/docs/manual/introduction/How-to-update-things.html @@ -69,14 +69,14 @@ var positions = new Float32Array( MAX_POINTS * 3 ); // 3 vertices per point geometry.addAttribute( 'position', new THREE.BufferAttribute( positions, 3 ) ); // draw range -drawCount = 2; // draw the first 2 points, only +var drawCount = 2; // draw the first 2 points, only geometry.setDrawRange( 0, drawCount ); // material var material = new THREE.LineBasicMaterial( { color: 0xff0000, linewidth: 2 } ); // line -line = new THREE.Line( geometry, material ); +var line = new THREE.Line( geometry, material ); scene.add( line );

@@ -85,7 +85,8 @@ scene.add( line ); var positions = line.geometry.attributes.position.array; -var x = y = z = index = 0; +var x, y, z, index; +x = y = z = index = 0; for ( var i = 0, l = MAX_POINTS; i < l; i ++ ) {