XRI Problem In VisionOS MR Mode

Hi,there
In unbounded MR scene,when one of my hands touches an object, I want to know which hand it is.
I added XRSimpleInteractable component to the 3D object,and I introduced several components like XRInteractionManager, InputActionManager, and XRTouchSpaceInteractor.
imageImage_20240423191302

And my code is as follows:


When this code is run in VisionOS, the code in the red box will report errors,what is the reason for this?
Maybe there’s another way to achieve my idea above?

I tried to print out the arg0’s information,it show arg0.interactorObject.transform:XRTouchSpaceInteractor.

How can I know which hand touched the object?

The Spatial Tap gesture API does not have handedness, ie: there is no way to tell from the API if the left or right hand is interacting with an object.

If you have both gestures detected you can setup some custom logic infer which is left and which is right based on their position. ie: interactionPosition.x < 0 = left hand, interactionPosition.x > 0 = right hand.

Hi,there.
Thank you very much for your reply.
Now I facing another problem. I added a welding gun model under the right hand to achieve a welding effec


But when it is run, the gun model will shake. I tested and found that this phenomenon seems to be caused by the shaking of the virtual hand.
I recorded a video on this issue but can’t upload it here.I hope I’ve described the difficulties I facing clearly.

Is there any way to eliminate this shake of gun(or hands)?