Search Unity

Feature Request Velocity tracking for a socketed interactable in XRToolkit?

Discussion in 'XR Interaction Toolkit and Input' started by colinleet, May 3, 2023.

  1. colinleet

    colinleet

    Joined:
    Nov 20, 2019
    Posts:
    189
    I was wondering if anyone on here happened to know if any altered versions of the socket intractable, which are customized to work like the velocity tracking used for a standard grip interactable?

    I am currently using the standard socket interactable for holsters on my player's body, but I dislike how it forces the weapons into a kinematic state as long as they're holstered. What I'm hoping for is to get some physics push-back like when using velocity tracking for held interactable, where if the player sticks their arm through a wall the gun would be blocked by the wall -- pushing against it -- such that if a object that is thrown at the player happens to clip the gun, it doesn't fully stop the object's motion but can be pushed around by it (a bit). Ideally this would come with a max force parameter, wherein if too large of a force is applied (e.g. over x newton's) the object can get knocked out of the holster. It would also be super useful to be able to tune what the socket's max counteracting force (in newton) could be for such situations.

    I am very willing to look at other XR toolkits if there are any others which have this type of interactable; probably with an eye towards adapting those solutions so they're compatible with how the XR toolkit handles these things too.