playMaker

Author Topic: VR hands not passing through walls?  (Read 538 times)

Adam Z

  • Full Member
  • ***
  • Posts: 171
    • View Profile
VR hands not passing through walls?
« on: July 01, 2020, 12:56:32 PM »
Hey everyone, does anyone have thoughts on the best way to achieve this? Instead of your hand going through a wall, your VR hand stops at the wall even though your real hand keeps moving forward. Then if you pull your real hand back and it passes the VR wall you went through, you VR hand springs back to the correct position. There's a good example in Half Life: Alyx.

I'm also interested on how I can achieve a VR hand rotating around the surface of an object.

Any thoughts would be helpful! Thanks.

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 5397
    • View Profile
    • jinxtergames
Re: VR hands not passing through walls?
« Reply #1 on: July 01, 2020, 02:41:44 PM »
Hi.
I have not worked with vr yet but i do use vr.

1st thing comes in mind is to have a 'empty object' to follow controller(real Hand)

Then have the VR hand object 'follow' the 'empty object' (real hand)

The follow part can be more tricky to do
the vr hand should have colliders and probably you will need some raycasts to for example stop following toward, but possibly still follow sideways.

But again, i have not tested vr in unity yet :)

Adam Z

  • Full Member
  • ***
  • Posts: 171
    • View Profile
Re: VR hands not passing through walls?
« Reply #2 on: July 01, 2020, 02:48:03 PM »
Then have the VR hand object 'follow' the 'empty object' (real hand)
The follow part can be more tricky to do
the vr hand should have colliders and probably you will need some raycasts to for example stop following toward, but possibly still follow sideways.
Thanks for your suggestions. I have a full body IK controller that's working, but I'm trying to make it a bit more immersive. I was thinking about also using Unity's Animation Rigging Tools in conjunction with what you suggested; colliders and raycasts for determining finger positions, etc. but I haven't had much success.

I figured I would throw my question out there to see if someone actually got this working, or has some ideas like you did. :)