Hello,
I am trying to activate the trigger button in oculus quest with Unity 2020 but doesn’t work, this is my code
InputDevice leftHandDevice;
private void Start()
{
leftHandDevice = InputDevices.GetDeviceAtXRNode(XRNode.LeftHand);
}
private void Update()
{
bool triggerValue;
if (leftHandDevice.TryGetFeatureValue(UnityEngine.XR.CommonUsages.triggerButton, out triggerValue) && triggerValue)
{
Debug.Log("Trigger button is pressed.");
}
}