Просмотр исходного кода

Merge pull request #13359 from takahirox/GLTFExporterNodeName

GLTFExporter: Add comment for empty strings name
Mr.doob 7 лет назад
Родитель
Сommit
3c86cd28c3
1 измененных файлов с 2 добавлено и 1 удалено
  1. 2 1
      examples/js/exporters/GLTFExporter.js

+ 2 - 1
examples/js/exporters/GLTFExporter.js

@@ -1203,7 +1203,8 @@ THREE.GLTFExporter.prototype = {
 
 			}
 
-			if ( object.name ) {
+			// We don't export empty strings name because it represents no-name in Three.js.
+			if ( object.name !== '' ) {
 
 				gltfNode.name = String( object.name );