Browse Source

replace .length with variable

vlucendo 7 years ago
parent
commit
0ace56e97c
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/extras/curves/CatmullRomCurve3.js

+ 1 - 1
src/extras/curves/CatmullRomCurve3.js

@@ -114,7 +114,7 @@ CatmullRomCurve3.prototype.getPoint = function ( t, optionalTarget ) {
 
 
 	if ( this.closed ) {
 	if ( this.closed ) {
 
 
-		intPoint += intPoint > 0 ? 0 : ( Math.floor( Math.abs( intPoint ) / points.length ) + 1 ) * points.length;
+		intPoint += intPoint > 0 ? 0 : ( Math.floor( Math.abs( intPoint ) / l ) + 1 ) * l;
 
 
 	} else if ( weight === 0 && intPoint === l - 1 ) {
 	} else if ( weight === 0 && intPoint === l - 1 ) {