소스 검색

SceneExporter2 exporting userData.

Mr.doob 12 년 전
부모
커밋
bd52f79c0f
1개의 변경된 파일3개의 추가작업 그리고 1개의 파일을 삭제
  1. 3 1
      examples/js/exporters/SceneExporter2.js

+ 3 - 1
examples/js/exporters/SceneExporter2.js

@@ -105,7 +105,7 @@ THREE.SceneExporter2.prototype = {
 			} else if ( object instanceof THREE.SpotLight ) {
 
 				data.type = 'SpotLight';
-				data.color = object.color.getHex();	
+				data.color = object.color.getHex();
 				data.intensity = object.intensity;
 				data.position = object.position.toArray();
 
@@ -131,6 +131,8 @@ THREE.SceneExporter2.prototype = {
 
 			}
 
+			data.userData = object.userData;
+
 			// parse children
 
 			if ( object.children.length > 0 ) {