mrdoob/three.js — Issue #1381: Line between two points
Author: ivankuzev
Created: 2012-02-23 04:08:50+00:00
State: open

i was trying to do a simple line between point a and point b?

var shipAnchorGeometry = new THREE.Geometry();
shipAnchorGeometry.vertices.push( new THREE.Vertex(0 ,0,0) );
shipAnchorGeometry.vertices.push( new THREE.Vertex(0 ,1,0) );

var shipAnchor = new THREE.Line(shipAnchorGeometry,this.materials.etc.grid)
shipAnchor.position.set(data.ships[i].position.x, data.ships[i].position.y, data.ships[i].position.z);
// shipAnchor.rotation.x = degreesToRadians(90);
shipAnchor.scale.multiplyScalar( 1000);
this.scene.add(shipAnchor)

it wont work and i dont know why...please tell me.