Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
// Before
xrContext.addToBindings(commonBindings, squeezeAction, "/input/squeeze/value");
xrContext.addToBindings(commonBindings, triggerAction, "/input/trigger/value");
xrContext.addToBindings(commonBindings, gripPoseAction, "/input/grip/pose");
xrContext.addToBindings(commonBindings, aimPoseAction, "/input/aim/pose");
xrContext.addToBindings(commonBindings, thumbstickAction, "/input/thumbstick");
xrContext.addToBindings(commonBindings, thumbClickAction, "/input/thumbstick/click");
xrContext.addToBindings(commonBindings, vibrateAction, "/output/haptic");
// After
xrContext.addToBindings(commonBindings, squeezeAction, Input::Squeeze::value);
xrContext.addToBindings(commonBindings, triggerAction, Input::Trigger::value);
xrContext.addToBindings(commonBindings, gripPoseAction, Input::Grip::pose);
xrContext.addToBindings(commonBindings, aimPoseAction, Input::Aim::pose);
xrContext.addToBindings(commonBindings, thumbstickAction, Input::thumbstick);
xrContext.addToBindings(commonBindings, thumbClickAction, Input::Thumbstick::click);
xrContext.addToBindings(commonBindings, vibrateAction, Output::haptic);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment