In the XR rig, I placed hands with a script to replace the controllers. The issue is that the hands do not change position, even when configuring it in Unity. I’m not sure if the problem lies in my script or if it’s related to the XR rig.
Hello there – we have an experimental AI bot that might be able to help you with your question. Would you like to try this out?
How it works:
Reply to the messages of the bot that end with a thread_id to interact with it and ask follow-up questions. You can also mention the bot directly in this channel to get help.
The script seems well-structured, but without seeing the specific Unity configuration or having more context on how the XR Rig and controller scripts are integrated, it’s hard to pinpoint the exact issue. I noticed in the provided code that there is logic in place to handle the visibility and orientation of the controllers and hands when entering or exiting VR, which looks correct.
Here are a few things to consider:
Make sure the Unity XR settings are configured to track the position and rotation of the controllers properly.
Ensure that your hands are properly parented to the controller objects in Unity, as the controllers’ position and rotation changes are what should move the hands in VR.
Verify that the XR rig is setup correctly and that no local transformations on the hand objects or their parents are overriding the controller’s transform.
If everything seems configured correctly, you may want to add logs to updateControllerTransform to ensure the code is getting and applying the controller positions to the hands properly. You might also want to check if any other scripts or Unity components are interfering with the hand transforms.
If you want to provide more information or context, like a snippet of the Unity hierarchy or specific issues encountered, I can give more targeted advice.
Hi, we will release a first version of a big webxr update adding new features and overall simplifiying and improving many of our features and apis the next few days (it will be a pre release first)
Hi, I updated needles to see what you have implemented, and well, the code I had created was essentially based on your shoot range that you have in your samples, where you use WebXR to check if the session is VR and for the controls. However, it seems that it’s no longer usable. I would like to know if you have documentation or any project with the new implementation to verify how it works now .
Another question I have is that when I enter VR from my computer using a VR extension, I encounter an error with the controls. However, when I enter from my Quest, I don’t have any problems. I’m wondering if the issue is with the extension. The only reason I use the VR extension is to be able to view the console. Is there any way to view the console from the Quest ? Thank you very much.
Hi! I’m trying to apply the new scripts that were implemented, but it’s not working as expected. I don’t know if I’m missing something. My issue is that I want the controls to be like guns, as in the shooting range example. However, once the guns appear in VR and work fine, they move with the controls, disappear, and I get this error
I added the XR Control Model and XR Control Movement to the XR component, and I have assigned the avatar. I have an XR rig where the avatar is placed, and I’m using the same gun script as in the shooting range. I don’t know where I’m going wrong