Explorar o código

Merge pull request #9381 from CedricGuillemet/lastSceneSixDofDrag

don't add sixDofDrag scene to the last created ones
David Catuhe %!s(int64=5) %!d(string=hai) anos
pai
achega
4317cae612
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/Behaviors/Meshes/sixDofDragBehavior.ts

+ 1 - 1
src/Behaviors/Meshes/sixDofDragBehavior.ts

@@ -98,7 +98,7 @@ export class SixDofDragBehavior implements Behavior<Mesh> {
         this._ownerNode = ownerNode;
         this._scene = this._ownerNode.getScene();
         if (!SixDofDragBehavior._virtualScene) {
-            SixDofDragBehavior._virtualScene = new Scene(this._scene.getEngine());
+            SixDofDragBehavior._virtualScene = new Scene(this._scene.getEngine(), {virtual: true});
             SixDofDragBehavior._virtualScene.detachControl();
             this._scene.getEngine().scenes.pop();
         }