Search Unity

Resolved XR Rig with gravity under player position.

Discussion in 'XR Interaction Toolkit and Input' started by xinuxano, May 11, 2021.

  1. xinuxano

    xinuxano

    Joined:
    Feb 28, 2018
    Posts:
    33
    In my VR project with the XR interaction toolkit, I only use the teleport to move the XR Rig from one place to another.

    I'm interested in the XR Rig having gravity (under the player's feet position), so that it always falls to the lowest surface below the player. At the moment I don't use character controller.

    How should I do it? any advice?

    Thanks in advance.
     
  2. Sab_Rango

    Sab_Rango

    Joined:
    Aug 30, 2019
    Posts:
    121
    Hey! try to set "skin width " property of CharacterController close to zero:)
     
  3. xinuxano

    xinuxano

    Joined:
    Feb 28, 2018
    Posts:
    33
    I solved it whit CharacterController and ContinuousMovement Script. Use gravity and inmediatly movement.
     
  4. tjex_

    tjex_

    Joined:
    Dec 13, 2021
    Posts:
    1
    This helped, thanks. But for me I had to remove the Character Controller Driver for some reason (which I had added after watching a tutorial). After removing the script, then gravity would work... No idea why.