Unity 5.6.0f3 Oculus rift crash when removed from the head when build

Hello! I’ve been creating a project and suddenly noticed a weird error after building my VR project. My unity version is 5.6.0f3 and just recently updated OVR to 1.13.0.

The problem is that when the Oculus rift hmd is not on users head, the game crashes. But if the headmount is on users head and oculus is active, it works. Anyone has any idea why is that? Or if anyone has noticed the same problem.

I have found a workaround that works for me. It looks like the crash happens when you take off the headset an there is no other camera in the scene than that of the oculus cameraRig. I fixed the problem with adding an additional non vr-camera in the background. Every time, i take off the headset this camera is rendered in the gamewindow instead of crashing the game.


Thanks for the heads up. What you mentioned fixed it for me as well.

Just wanted to add that for this fix to work, the “fallback” camera need to have the Depth value lower than any other VR cameras in your scene.

I already had a setup in my scene with a non-vr cam for the monitor only to render. The Depth value
was above my VR cams and the crash still occurred.

Had the same issue: https://forum.unity3d.com/threads/unity-5-6-0r3-build-crashing-when-rift-is-plugged.465708/

Turned out it was caused by the anti-aliasing setting - as soon as I turned it off, the crashing stopped.

I am using Unity 5.6 0f3 and OVR plugin 1.14 version. i have removed the headset numerous times and play without headset most of the time. This issue is fixed in 1.14 version. Please upgrade to that.