Forum Discussion
Theformand
9 years agoProtege
[Bug report / Tip] Unity 5.5 freezing on start while VR support is not enabled. Caused by OVRHaptics
Hello.
Some info:
Unity 5.5.0f3.
Newest Oculus SDK UnityPackage (I dont see a readme.txt with version number or anything), at the time of writing.
Newest OVRAvatar UnityPackage (same).
I have been trying to debug a strange issue that I encountered when trying to build a Non-VR mode for team mates with no headset.
If I disabled VR Support in player settings, or simply disconnected my Rift, Unity would freeze when hitting Play. No way out of it, other than to kill Unity and try again.
This appears to be caused by me initalizing OVRHapticsClips a few places in Start / Awake. If I stop doing this, Unity runs fine.
Repro steps are:
Step 1: Have a class with an OVRHapticsClip declared.
Step 2: Initialize the clip with the new OVRHapticsClip(AudioClip clip) overload.
Step 3: Go to player settings and disable VR support.
Step 4: Press Play.
For now, the best workaround I found is to check VRDevice.isPresent before init'ing any clips.
Happy dev'ing. Hope this helps the Oculus team as well.
Some info:
Unity 5.5.0f3.
Newest Oculus SDK UnityPackage (I dont see a readme.txt with version number or anything), at the time of writing.
Newest OVRAvatar UnityPackage (same).
I have been trying to debug a strange issue that I encountered when trying to build a Non-VR mode for team mates with no headset.
If I disabled VR Support in player settings, or simply disconnected my Rift, Unity would freeze when hitting Play. No way out of it, other than to kill Unity and try again.
This appears to be caused by me initalizing OVRHapticsClips a few places in Start / Awake. If I stop doing this, Unity runs fine.
Repro steps are:
Step 1: Have a class with an OVRHapticsClip declared.
Step 2: Initialize the clip with the new OVRHapticsClip(AudioClip clip) overload.
Step 3: Go to player settings and disable VR support.
Step 4: Press Play.
For now, the best workaround I found is to check VRDevice.isPresent before init'ing any clips.
Happy dev'ing. Hope this helps the Oculus team as well.
1 Reply
Replies have been turned off for this discussion
- TheformandProtegeThanks for following up!
Quick Links
- Horizon Developer Support
- Quest User Forums
- Troubleshooting Forum for problems with a game or app
- Quest Support for problems with your device
Other Meta Support
Related Content
- 11 months ago
- 3 years ago