浏览代码

Updated JSM.

Mugen87 5 年之前
父节点
当前提交
df9cb26d48
共有 1 个文件被更改,包括 3 次插入0 次删除
  1. 3 0
      examples/jsm/exporters/GLTFExporter.js

+ 3 - 0
examples/jsm/exporters/GLTFExporter.js

@@ -1668,6 +1668,9 @@ GLTFExporter.prototype = {
 			var node = outputJSON.nodes[ nodeMap.get( object ) ];
 			var node = outputJSON.nodes[ nodeMap.get( object ) ];
 
 
 			var skeleton = object.skeleton;
 			var skeleton = object.skeleton;
+
+			if ( skeleton === undefined ) return null;
+
 			var rootJoint = object.skeleton.bones[ 0 ];
 			var rootJoint = object.skeleton.bones[ 0 ];
 
 
 			if ( rootJoint === undefined ) return null;
 			if ( rootJoint === undefined ) return null;