private void Update() { if (VRInput.GetDown(GenericVRButton.Hand, handedness)) { Grab(); } else if (VRInput.GetUp(GenericVRButton.Hand, handedness)) { Drop(); } }
private Queue <Vector3> velocityInputs = new Queue <Vector3>(); //calculate to handle throwing private void Update() { UpdateVelocity(); print(velocityInputs); if (VRInput.GetDown(GenericVRButton.Hand, handedness)) { Grab(); } else if (VRInput.GetUp(GenericVRButton.Hand, handedness)) { Drop(); } }
private void Update() { UpdateVelocity(); if (VRInput.GetDown(GenericVRButton.Hand, handedness)) { Grab(); } else if (VRInput.GetUp(GenericVRButton.Hand, handedness)) { Drop(); } if (grabbedComponent) { grabbedComponent.CheckForUse(); } }