Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.

Question XR RIG Movement Speed

Discussion in 'VR' started by Freakish, Jul 19, 2022.

  1. Freakish


    Jun 3, 2015
    I've been trying for the most part of the day to determine the player movement speed with XR and Quest2. (PCVR).

    I can get a speed when using Locomotion, but I'm after the speed at which I the player walk around my physical space.

    I've tried comparing a bunch of transform positions, and also tried looking at various velocities from controllers and HMD, and even accessing the CharacterController velocity, but none of these are helping....

    I assume it would be something like the difference between MainCamera(HMD) local and worldspace, but cannot seem to get anything useful. (OldPos vs NewPos).

    Any ideas on how to determine a speed I'm walking around at?

    Thanks for any help/advice.
  2. DevDunk


    Feb 13, 2020
    Compare the position of the camera in fixedupdate (or update if you take into account deltatime)