Forum Discussion
magnimus_studios
2 years agoPartner
Unable to detect whether the interactor unselected or not
I am trying to create a socket for my weapon system, where you can grab the weapon within the collider. I am using interactor.ForceSelect() method to attach the weapon grabbable to the hand or controller but the issue is that the interactor is not ungrabbing the grabbable. The interactorAdded event is working fine but interactorRemoved events are null.
Is the any way to detect the weapon release?
How to make this weapon socket work properly with the sdk?
Hi magnimus_studios, it sounds like you're using Interaction SDK, so instead of using the ForceSelect() method, I would use QuickActions to automatically add a grab interaction to your weapon. You could then expand the collider on the weapon so the grab triggers even if your hand isn't touching the weapon mesh.
If for some reason you need to use the ForceSelect() method, both the HandGrabInteractor and GrabInteractor have a ForceRelease() method you could use to make the interactor release the weapon.
If none of that answers your question, could you share a video or screenshot of what you're seeing and explain what you expect to happen instead? Thanks!
1 Reply
- Big_FlexMeta Employee
Hi magnimus_studios, it sounds like you're using Interaction SDK, so instead of using the ForceSelect() method, I would use QuickActions to automatically add a grab interaction to your weapon. You could then expand the collider on the weapon so the grab triggers even if your hand isn't touching the weapon mesh.
If for some reason you need to use the ForceSelect() method, both the HandGrabInteractor and GrabInteractor have a ForceRelease() method you could use to make the interactor release the weapon.
If none of that answers your question, could you share a video or screenshot of what you're seeing and explain what you expect to happen instead? Thanks!
Quick Links
- Horizon Developer Support
- Quest User Forums
- Troubleshooting Forum for problems with a game or app
- Quest Support for problems with your device
Other Meta Support
Related Content
- 9 months ago
- 7 months ago