Forum Discussion

🚨 This forum is archived and read-only. To submit a forum post, please visit our new Developer Forum. 🚨

2 Replies

  • For application entitlement, it's basically this (for Unity - C++ should make the equivalent C++ function call):






    Oculus.Platform.Entitlements.IsUserEntitledToApplication().OnComplete(IsUserEntitledToApplicationCallback); 

    private void IsUserEntitledToApplicationCallback(Message msg) {

          if (!msg.IsError) {

             //Debug.Log("Application is entitled.");

          } else {

             //Debug.Log("Application is NOT entitled.");
             // DO NOT RUN IF APP isn't entitled (unless we are in editor)

             #if !UNITY_EDITOR

             UnityEngine.Application.Quit(); // Or maybe throw up some other kind of notice that blocks progress

             #endif

          }

    }




    What is weird, though, is that this essentially requires you to have the Platform SDK linked to your project, even if you are not using any other platform features. Also weird, is that I swear someone in the documentation is a line that says Unity handled application entitlement for you - but I guess that is only for debug builds.

    The VR focus management doc link works for me, so not sure what is giving you the 404 there.
  • Let me get someone to fix those links. Thanks for spotting this.