0

Using the Vive controllers, I want to be able to trigger-click-and-hold on an object in my A-Frame scene, and be able to then move and rotate that object in the space of the VR scene, by moving the controller in space.

One way I can think of doing this is: on trigger pull, to make the object a child of the controller, so it inherits position and rotation from the controller.

In Three.js, I could use:

THREE.SceneUtils.detach( child, parent, scene ); THREE.SceneUtils.attach( child, scene, parent );

How can I set/remove parent on gripup/gripdown events in A-Frame?

1 Answers1

0

One of the A-Frame examples does what you describe, actually.

Here's the scene index.html, grab component, and a demo.

Don McCurdy
  • 10,975
  • 2
  • 37
  • 75