Explorar el Código

show errors when creating XR in non-XR environment

Raanan Weber hace 5 años
padre
commit
e8c849ac6a
Se han modificado 1 ficheros con 5 adiciones y 0 borrados
  1. 5 0
      src/Cameras/XR/webXRDefaultExperience.ts

+ 5 - 0
src/Cameras/XR/webXRDefaultExperience.ts

@@ -7,6 +7,7 @@ import { WebXREnterExitUI, WebXREnterExitUIOptions } from './webXREnterExitUI';
 import { AbstractMesh } from '../../Meshes/abstractMesh';
 import { AbstractMesh } from '../../Meshes/abstractMesh';
 import { WebXRManagedOutputCanvasOptions } from './webXRManagedOutputCanvas';
 import { WebXRManagedOutputCanvasOptions } from './webXRManagedOutputCanvas';
 import { WebXRMotionControllerTeleportation } from './features/WebXRControllerTeleportation';
 import { WebXRMotionControllerTeleportation } from './features/WebXRControllerTeleportation';
+import { Logger } from '../../Misc/logger';
 
 
 /**
 /**
  * Options for the default xr helper
  * Options for the default xr helper
@@ -116,6 +117,10 @@ export class WebXRDefaultExperience {
             }
             }
         }).then(() => {
         }).then(() => {
             return result;
             return result;
+        }).catch((error) => {
+            Logger.Error("Error initializing XR.");
+            Logger.Error(error);
+            return result;
         });
         });
     }
     }