linbingquan 4 år sedan
förälder
incheckning
08d1424a72
2 ändrade filer med 3 tillägg och 1 borttagningar
  1. 1 1
      editor/js/Menubar.File.js
  2. 2 0
      editor/js/Storage.js

+ 1 - 1
editor/js/Menubar.File.js

@@ -271,7 +271,7 @@ function MenubarFile( editor ) {
 
 
 		var exporter = new GLTFExporter();
 		var exporter = new GLTFExporter();
 
 
-		exporter.parse( editor.scene, function ( result ) {
+		exporter.parse( scene, function ( result ) {
 
 
 			saveString( JSON.stringify( result, null, 2 ), 'scene.gltf' );
 			saveString( JSON.stringify( result, null, 2 ), 'scene.gltf' );
 
 

+ 2 - 0
editor/js/Storage.js

@@ -30,6 +30,7 @@ function Storage() {
 				}
 				}
 
 
 			};
 			};
+
 			request.onsuccess = function ( event ) {
 			request.onsuccess = function ( event ) {
 
 
 				database = event.target.result;
 				database = event.target.result;
@@ -37,6 +38,7 @@ function Storage() {
 				callback();
 				callback();
 
 
 			};
 			};
+
 			request.onerror = function ( event ) {
 			request.onerror = function ( event ) {
 
 
 				console.error( 'IndexedDB', event );
 				console.error( 'IndexedDB', event );