diff --git a/src/extras/helpers/ArrowHelper.js b/src/extras/helpers/ArrowHelper.js index c0fb8d87562c1eee18b6e89f659c0783b79cd124..ac7eb70ec682be6e812ad7c88429cad484e12e92 100644 --- a/src/extras/helpers/ArrowHelper.js +++ b/src/extras/helpers/ArrowHelper.js @@ -9,18 +9,18 @@ * dir - Vector3 * origin - Vector3 * length - Number - * hex - color in hex value + * color - color in hex value * headLength - Number * headWidth - Number */ -THREE.ArrowHelper = function ( dir, origin, length, hex, headLength, headWidth ) { +THREE.ArrowHelper = function ( dir, origin, length, color, headLength, headWidth ) { // dir is assumed to be normalized THREE.Object3D.call( this ); - if ( hex === undefined ) hex = 0xffff00; + if ( color === undefined ) color = 0xffff00; if ( length === undefined ) length = 1; if ( headLength === undefined ) headLength = 0.2 * length; if ( headWidth === undefined ) headWidth = 0.2 * headLength; @@ -31,14 +31,14 @@ THREE.ArrowHelper = function ( dir, origin, length, hex, headLength, headWidth ) lineGeometry.vertices.push( new THREE.Vector3( 0, 0, 0 ) ); lineGeometry.vertices.push( new THREE.Vector3( 0, 1, 0 ) ); - this.line = new THREE.Line( lineGeometry, new THREE.LineBasicMaterial( { color: hex } ) ); + this.line = new THREE.Line( lineGeometry, new THREE.LineBasicMaterial( { color: color } ) ); this.line.matrixAutoUpdate = false; this.add( this.line ); var coneGeometry = new THREE.CylinderGeometry( 0, 0.5, 1, 5, 1 ); coneGeometry.applyMatrix( new THREE.Matrix4().makeTranslation( 0, - 0.5, 0 ) ); - this.cone = new THREE.Mesh( coneGeometry, new THREE.MeshBasicMaterial( { color: hex } ) ); + this.cone = new THREE.Mesh( coneGeometry, new THREE.MeshBasicMaterial( { color: color } ) ); this.cone.matrixAutoUpdate = false; this.add( this.cone );