Skip to main content
June 27, 2013

How to set default Player Height?

Using the OVR character to controller, where do you set the default player height?

I can change it with 5,6, but can't seem to find where it sets the default of 1.85.
    This topic has been closed for replies.

    6 replies

    June 27, 2013
    I found that its set in playerpref, but no idea how or where to set that outside of editing the playerpref file directly. Thoughts?
    Inspiring
    June 27, 2013
    You should be able to edit the 'height' value in the character controller component (on the OVRPlayerController prefab).
    AMD Ryzen 7 1800X | MSI X370 Titanium | G.Skill 16GB DDR4 3200 | EVGA SuperNOVA 1000 | Corsair Hydro H110i Gigabyte RX Vega 64 x2 | Samsung 960 Evo M.2 500GB | Seagate FireCuda SSHD 2TB | Phanteks ENTHOO EVOLV
    Participant
    June 29, 2013
    If you set the height value, the "Player Height" in VRVariables menu (hit spacebar) still displays 1,85m
    I wanted to find out why, and it's because the OVRMainMenu script doesn't check the capsule height, but calculates it from the default height of 2.0. Would be nice to fix that at some point...
    Inspiring
    July 1, 2013
    Sorry, my bad.

    You actually want to edit the "Neck Position" Y-value in OVRCameraController in the editor.

    This will update the value in the OSD.
    AMD Ryzen 7 1800X | MSI X370 Titanium | G.Skill 16GB DDR4 3200 | EVGA SuperNOVA 1000 | Corsair Hydro H110i Gigabyte RX Vega 64 x2 | Samsung 960 Evo M.2 500GB | Seagate FireCuda SSHD 2TB | Phanteks ENTHOO EVOLV
    Participant
    July 17, 2013
    Hi,

    just if someone is interested, I've tweaked the OVRCameraControler Script, so it sets the Neck and Eye Position automaticly depending on the the Character Controlers height ( = your actual body height )

    I calculate the values according to this relations: http://mech.utah.edu/ergo/pages/Educational/safety_modules/ctd-anthropometry/index_files/image002.gif

    Just add the following code to the Start() function:

    // manually enter the unexposed skinwidth parameter from the character controller here
    float skinwidth = 0.08f;

    // calculate distances
    float height = transform.parent.GetComponent<CharacterController>().height ;
    NeckPosition.y = 0.87f*height-height/2f- skinwidth;
    EyeCenterPosition.y = 0.936f*height - NeckPosition.y -height/2f - skinwidth;


    EDIT: this is porbably redudant when you use the IPD.
    New Participant
    October 11, 2015
    var p = CameraRig.transform.localPosition;
    p.y = OVRManager.profile.eyeHeight - 0.5f * Controller.height

    change eyeHeight to 0.2 f
    it will work