Browse Source

Object3D: Pointer to children in updateMatrixWorld().

Mr.doob 9 years ago
parent
commit
5deb25e238
1 changed files with 4 additions and 2 deletions
  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 );
 
 		}