Explorar el Código

Object3D: Pointer to children in updateMatrixWorld().

Mr.doob hace 9 años
padre
commit
5deb25e238
Se han modificado 1 ficheros con 4 adiciones y 2 borrados
  1. 4 2
      src/core/Object3D.js

+ 4 - 2
src/core/Object3D.js

@@ -543,9 +543,11 @@ Object.assign( Object3D.prototype, EventDispatcher.prototype, {
 
 		// update children
 
-		for ( var i = 0, l = this.children.length; i < l; i ++ ) {
+		var children = this.children;
+
+		for ( var i = 0, l = children.length; i < l; i ++ ) {
 
-			this.children[ i ].updateMatrixWorld( force );
+			children[ i ].updateMatrixWorld( force );
 
 		}
 

粤ICP备19079148号