lovr.headset.isDown

Edit

Returns whether a button on a device is pressed.

down = lovr.headset.isDown(device, button)

Arguments

NameTypeDescription
deviceDevice The device.
buttonDeviceButton The button.

Returns

NameTypeDescription
downboolean Whether the button on the device is currently pressed, or nil if the device does not have the specified button.

Notes

When hand tracking is active, pinching will be mapped to the trigger button.

See also