提交 549f3ab6 编写于 作者: A Alexander Fallenstedt 提交者: GitHub

Fix typo with stars geometry

There was no instance of 'geometry', yet vertices were being added to it, and a mesh was being created from it.
上级 1d8d621e
......@@ -44,13 +44,13 @@ for ( var i = 0; i < 10000; i ++ ) {
star.y = THREE.Math.randFloatSpread( 2000 );
star.z = THREE.Math.randFloatSpread( 2000 );
geometry.vertices.push( star );
starsGeometry.vertices.push( star )
}
var starsMaterial = new THREE.PointsMaterial( { color: 0x888888 } )
var starField = new THREE.Points( geometry, starsMaterial );
var starField = new THREE.Points( starsGeometry, starsMaterial );
scene.add( starField );
</code>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册