I’m using unity 2018.3.7f1 with the oculus integration 1.35. The teleportation demo scene is acting strange. When you teleport using the thumbstick it moves you to the desired spot then to another spot far behind where you started. In most cases it’s so far back you fall off the ground plane. I’ve tried messing with all the components but haven’t found anything that fixes it. Anyone else having this problem or know how to fix it?
I’ve been working with the Oculus teleportation recently in Unity 2018.2.17 and it seems to work fine. I believe I have the 1.35 in integration. Are you using the capacitive setting to trigger teleport? If so, could a finger too close to the button be triggering a teleport?
I don’t change anything in the demo scenes. However they are set up is how I leave it. It’s strange because sometimes it teleports fine and the rest of the time it blasts me out into space. It doesn’t seem to have anything to do with the capacitive setting. If I am really careful not to touch anything but the joystick it still happens.
I did some more testing and it seems like a force is being applied to my playercontroller. I am unable to teleport out into the areas I am falling so I don’t believe it is a accidental teleport. It’s more like I’m colliding with something that’s applying a huge horizontal force. I added walls surrounding the playspace and that keeps the playercontroller contained but it gets blasted back into the walls. Always horizontal though. Never vertically.
So Unity 2018.2.0f2 works without the teleportation glitch. What didn’t work was Unity 2018.3.0f2, 2018.3.8f1, 2018.3.7f1, and 2019.2.0a6. These all had the same teleport glitch.
For now I am commenting out the following line in LocomotionTeleport.cs in the function DoTeleport(). This makes the glitch go away. I’m not sure yet if this is going to cause me any other problems but it gets me working for now.
788| LocomotionController.PlayerController.Teleported = true;
I have exprienced the same issue. For whatever reason some times it works sometimes I get that “push back effect” you mention. I also found that line and commented it out. But what happens is that sometimes I get teleported inside the geometry of the scene. So strange…
Thanks for the tip about Unity versions.
I forget where I read that the Oculus integration package is NOT working (yet) with the newer versions of Unity.
https://developer.oculus.com/downloads/package/unity-integration/
This bouncing problem seems to still be there in Unity 2019.1.3f1
Did anyone figure it out :)?
Thanks for that! You saved the day for me!
You may want to increase the “Fixed Timestep” value (within the Unity editor, under the Edit → Project Settings → Time menu) to match the max framerate of your device. This value determines the rate at which your physics objects update; this is set to 0.2 as default within Unity (50Hz). You can refer to the following chart to determine which values to enter based on device:
50Hz (Default) = 0.2
60Hz (Gear VR) = 0.0167
72Hz (Quest/Oculus Go) = 0.0138
80Hz (Rift S) = 0.125
90Hz (Rift) = 0.0111
This not only makes the physics within your experience smoother, but it also solves the issues around teleporting.
I changed the Fixed Timestep as @Kyodan suggested, as well as commented out the line @CWatsonT2 pointed to. I no longer get the crazy bouncing around the scene, but I now have one last strange issue.
When teleporting, my X and Z coordinates are correct, but if the point is lower in elevation than where I’m standing, the character controller is only shifted to a spot above the destination, and I’m then dropped down (which creates a pretty terrible sensation). This despite me modifying the LocomotionTeleport.cs script to even raycast to the ground and specifically place me at that point.
Looking into the PlayerController a bit, it looks like that Teleported flag is used to prevent conflicting movements from interfering with each other (such as the movement of the HMD). So while having that not set to true prevents the bouncing, it looks like there’s some sort of vertical movement that’s now being inhibited because of it.
Either of your guys experience this, or know of a potential workaround?
I’m currently experiencing the same problem: when I teleport I randomly fall through the floor.
I have tried:
- To change the fixed timestamp to several values: 1/90 (90Hz) or 1/72(72Hz)
- Using a thin cube instead of a plane for the floor.
Nothing works.
I’m using Unity 2019.1.9f1 with Oculus integration 1.38 and the teleport with parabolic handler and deploying on Oculus Quest
That worked for me! (Unity version 2018.3.14) Thank you
I’m glad I’m not alone, same issue here on 2019.2.0f1 Whilst looking through the Oculus dev docs I did notice this…
Recommended Unity Versions
We recommend using one of the following Unity versions for all Oculus development.
- 2017.4 LTS
- 2018.4 LTS
- 2019.1.2f1
Not tried with those specific versions but looks like they test against those and probably be ok there?
You might think that, but I’ve tried with those specific versions (2018.4 LTS and 2019.1.2f1) and this same issue – along with many others – are present. As much as I enjoy my Oculus headsets and the software that runs on them, the Unity integration is pretty trash.
Honestly, the best thing I’ve found to do is use the Oculus-provided code only as a reference and example, and write your own scripts with a form of implementation of the features you want. There’s just so many parts and dependencies to the Oculus stuff that it breaks too easily.
@Schneider21 Thats disappointing to hear regarding the specific versions with the same issues. I spent quite a bit of time just working out I needed to enter an App ID in the Oculus settings due to recent change as well regarding Avatars. Before that I couldn’t get any teleporting to work at all.
Generally I’m having a really confusing time of stuff with Unity and VR with my Rift and have just started another post in the VR forum to try and get some help around it all. I honestly came into Unity expecting VR on-boarding, best practises and getting started to be pretty smooth but for me it hasn’t been at all
Thank you so much for this. I’ve been absolutely wrecking my brain trying to figure out why i get the push back effect for 2.5 days! Tried mulitple versions of unity with the different Oculus Integration versions…
2018.2.0f2, Oculus Integration 1.35 and misc tries with java sdk’s and androids sdk’s later I’ve finally got it!
You are a life saver!!
The Oculus Integration 1.40 includes a “Character Camera Constraint” script that you need to add to the same GameObject that contains your “OVR Player Controller”. This took care of the above mentioned issue for me on Unity 2019.2.4f
Just Replace to this script, this script working perfectly i am just doing the CharacterController disable on pre-teleport and enable the post-teleport on DoTeleport method line no.761
4972088–484382–LocomotionTeleport.cs (34.2 KB)
Not sure if it’s the same teleport glitch, but i have serious issue with teleportation, even with the sample framework locomotion scene : aiming is good, but my Player Controller is systematically pushed backward. I use Oculus integration 1.40 with Unity 2019.2.2f1. I’m trying to upgrade to the latest 2019.2.6f1… fingers crossed…