Hi
I’m using oculus integration pack, with OVRGrabbable and OVRGrabber scripts.
I want to spawn an oject in the player hand, that would behave like if the player grabbed it
Anyone know how to make the grab action via script ?
I tryed bottle.GetComponent<OVRGrabbable>().GrabBegin(hand, grabPoint);
but this doesn’t seems to be the way
Usually you parent the object to a specific transform in the hand or below the controller to snap it into place.
Have you asked around this forum:
yes, here : https://discussions.unity.com/t/843180
Using the OVRGrabber script, it doesn,t seems to parent the OVRGrabbable gameobject. It stay unparented in the hierarchy
Interesting. I’m guessing they have some other connection that gets set up during a “grab” that says “I’m holding onto that thing so I will drive its position and rotation.”
Check the docs and see if they tell you anything about how they drive the position of the held object, and if there is a way to get inside that without the normal grab sequence. I would be surprised if that truly isn’t possible, but you never know with someone else’s API!