Remote grab XR Ray Interactor messes up XR input, direct grab doesn't

Hi there,

I’m running in this issue and can’t figure out what is happening. I use an XR Rig with among others a XR Direct Interactor for default grab and a XR Ray Interactor for remote grab.

Strange thing is that when I grab remotely via the XR Ray Interactor, the snap turn provider is not working anymore and the grabbed object is rotating instead.

With direct grab it is all working as intended.

See video of the issue.

Anyone knows what is causing this issue and how to fix it?

Cheers!

  • Bender

This is managed by the action manager on the root controller object. It’s a sample script that turns on and off input actions according to what you’re doing. There’s also an option on the ray interactor to turn off anchor manipulation that should address this.

Also worth noting that xri 3.0 replaces the ray and direct interactor and uses gestures to move objects closer and further during a grab, and it should work as you expect out of the box.

Thanks. I already noticed the anchor manipulation settings, but these are fully disabling the snap turn input.

I will try the xri 3, already installing…

@ericprovencher Upgrading to 3.0.1 is breaking a lot of things. So for now I want to try to first fix it on xri 2. Is there an easy way to fix my problem? Or should I change the sample scripts?

Thanks in advance!!

Yeah so in XRI 2.5, the way to solve this is by editing this script.

It’s a part of the samples so it’s editable in your project. Look for where the snap turn is turned off, and you can change that behavior.

Thanks a lot @ericprovencher ! This fixed my problem. I wasn’t realizing that the script was a test script.

For anyone bumping into the same issue, I now disabled the snap turn toggle in the script @ericprovencher is pointing at:

        void UpdateLocomotionActions()
        {
            // Disable/enable Teleport and Turn when Move is enabled/disabled.
            SetEnabled(m_Move, m_SmoothMotionEnabled);
            SetEnabled(m_TeleportModeActivate, !m_SmoothMotionEnabled);
            SetEnabled(m_TeleportModeCancel, !m_SmoothMotionEnabled);

            // Disable ability to turn when using continuous movement
            SetEnabled(m_Turn, !m_SmoothMotionEnabled && m_SmoothTurnEnabled);
            //SetEnabled(m_SnapTurn, !m_SmoothMotionEnabled && !m_SmoothTurnEnabled);
        }

        void DisableLocomotionActions()
        {
            DisableAction(m_Move);
            DisableAction(m_TeleportModeActivate);
            DisableAction(m_TeleportModeCancel);
            DisableAction(m_Turn);
            //DisableAction(m_SnapTurn);
        }

Also on the XR Ray Interactor script I disabled Anchor Control.

Cheers!!

  • Bender
1 Like