|
@@ -526,17 +526,17 @@ Object.assign( Object3D.prototype, EventDispatcher.prototype, {
|
|
|
|
|
|
updateMatrixWorld: function ( force ) {
|
|
updateMatrixWorld: function ( force ) {
|
|
|
|
|
|
- if ( this.matrixAutoUpdate === true ) this.updateMatrix();
|
|
|
|
|
|
+ if ( this.matrixAutoUpdate ) this.updateMatrix();
|
|
|
|
|
|
- if ( this.matrixWorldNeedsUpdate === true || force === true ) {
|
|
|
|
|
|
+ if ( this.matrixWorldNeedsUpdate || force ) {
|
|
|
|
|
|
- if ( this.parent === null ) {
|
|
|
|
|
|
+ if ( this.parent ) {
|
|
|
|
|
|
- this.matrixWorld.copy( this.matrix );
|
|
|
|
|
|
+ this.matrixWorld.multiplyMatrices( this.parent.matrixWorld, this.matrix );
|
|
|
|
|
|
} else {
|
|
} else {
|
|
|
|
|
|
- this.matrixWorld.multiplyMatrices( this.parent.matrixWorld, this.matrix );
|
|
|
|
|
|
+ this.matrixWorld.copy( this.matrix );
|
|
|
|
|
|
}
|
|
}
|
|
|
|
|