فهرست منبع

Fixed StandardNode.copy

Daniel Sturk 6 سال پیش
والد
کامیت
a9518ccb5f
1فایلهای تغییر یافته به همراه4 افزوده شده و 2 حذف شده
  1. 4 2
      examples/jsm/nodes/materials/nodes/StandardNode.js

+ 4 - 2
examples/jsm/nodes/materials/nodes/StandardNode.js

@@ -468,9 +468,11 @@ StandardNode.prototype.copy = function ( source ) {
 	if ( source.ambient ) this.ambient = source.ambient;
 
 	if ( source.environment ) this.environment = source.environment;
-	
+
 	if ( source.sheen ) this.sheen = source.sheen;
 
+	return this;
+
 };
 
 StandardNode.prototype.toJSON = function ( meta ) {
@@ -511,7 +513,7 @@ StandardNode.prototype.toJSON = function ( meta ) {
 		if ( this.ambient ) data.ambient = this.ambient.toJSON( meta ).uuid;
 
 		if ( this.environment ) data.environment = this.environment.toJSON( meta ).uuid;
-		
+
 		if ( this.sheen ) data.sheen = this.sheen.toJSON( meta ).uuid;
 
 	}