Forum Discussion

🚨 This forum is archived and read-only. To submit a forum post, please visit our new Developer Forum. 🚨
Dreamwriter's avatar
Dreamwriter
Rising Star
11 years ago

Unity, how do I dismiss the Health/Safety Warning?

I've got this in an update function, SDK 4.3:

		if (OVRManager.isHSWDisplayed)
{
if (Input.anyKeyDown)
{
OVRManager.DismissHSWDisplay();
}
}


...but it doesn't work, the warning stays displayed for a few seconds even if the player touches a key. Since the message specifically says to press a key to acknowledge, I need to make it go away when the player presses the key. Am I doing something obviously wrong?

10 Replies

  • drash's avatar
    drash
    Heroic Explorer
    This is part of the reason for the "outrage" about the HSW. There's actually a hidden but required countdown that must elapse before it can be dismissed, leading to confusion and a feeling that it is unresponsive to input with a mind of its own. I believe the countdown is around 6 seconds.

    So, if the player presses any key *before* 6 seconds is up, the HSW will disappear when 6 seconds is up.
    Or, If the player presses any key *after* the 6 seconds is up, the HSW will disappear immediately.

    Hope that helps.
  • Yes, there is a minimum amount of time the warning must be showed for. This is intended.
  • "cybereality" wrote:
    Yes, there is a minimum amount of time the warning must be showed for. This is intended.

    Then it should display a countdown timer after the user presses the key, or not tell you to press a key until that time . To the end user, pressing the button as they are told to do and nothing happening at all just feels like a bug, makes it feel unresponsive and makes people keep pressing buttons (or worse, lift up the headset to make sure they are pressing real keys and not like shift or control).
  • Yeah, I agree it's confusing. I can ask about getting the message improved.
  • I think it might be better if it were either implemented within the scene (ie the developer has to implement it) or if it were less intrusive or just a one-time thing (maybe per-application). I definitely see the legal reasons behind it, but it does get extremely annoying when you're developing and having to restart the application constantly to test.
  • "shinyquagsire23" wrote:
    it does get extremely annoying when you're developing and having to restart the application constantly to test.

    You can disable it for development. Check the documentation.
  • I would like to completely disable it. It is hard to explain to a client why Oculus comes up with such a terrible looking warning dialog every time. It completely breaks the design of the UI we have.
  • "cybereality" wrote:
    You can disable it for development. Check the documentation.

    Yeah, that's right. Section 7.2 of the developer guide says that you have to create a registry key in Windows. The doc says:
    For Windows, the following key must be added if the Windows OS is 32-bit:
    HKEY LOCAL MACHINE\Software\Oculus VR, LLC\LibOVR\HSWToggleEnabled
    If the Windows OS is 64-bit, then the path will be slightly different:
    HKEY LOCAL MACHINE\Software\Wow6432Node\Oculus VR, LLC\LibOVR\HSWToggleEnabled

    Notice that the LibOVR key (something like a folder, in regedit) doesn't exist, so you have to create it. Similarly, the HSWToggleEnabled should be created as a DWORD (32 bit) or QWORD (64 bit) value and must be set to a value of 1.

    After all this, you have only enabled a checkbox inside the Rift Configuration Utility. So open the Configuration Utility, click on "Advanced..." and you should see a new checkbox whose label is "Disable Health and Safety Warning", enable it and click "I Agree" on the window that will pop up. Now you have disabled the Warning for your pc.
    I've read in this forum that this looooong procedure still doesn't work for older demos or for some UDK stuff, but I've not tried them, so I do not know what to say about that.

    "MartinSchultz" wrote:
    I would like to completely disable it. It is hard to explain to a client why Oculus comes up with such a terrible looking warning dialog every time. It completely breaks the design of the UI we have.


    Regarding your clients you can:
    - Provide an installer that makes this procedure along with your program installation;
    - Provide an instruction file about how to disable it (they can't be n00bs, anyway);
    - Provide an installation service where you go to their home/factory/whatever and disable the warning;
    - Stop programming on Oculus and become a famous rockstar :)

    Hope this helps :)
  • Thanks TonyVR!

    P.S. I was a famous rock star and now I'm Oculus developer... :-)