Forum Discussion

🚨 This forum is archived and read-only. To submit a forum post, please visit our new Developer Forum. 🚨
barlogaa's avatar
barlogaa
Honored Guest
5 years ago

Oculus Integration as custom package dependency

Hi, is there a way to declare Oculus Integration as a dependency or have it linked somehow to a custom UPM package?

 

I am trying to build a custom core package with Quest hand-tracking setup and a couple of features to be able to reuse them in multiple projects. Since Oculus Integration is available as an asset instead of a UPM package, I cannot reference the dependency in the manifest. Attempt to move the whole Oculus Integration folder from project Assets to my custom package failed.

 

According to this answer from Unity, Unity Asset store packages are a legacy way to share content and new assets should be switching to UPM. Any chances Oculus is planning to switch to UPM soon?

 

I would appreciate any suggestions!

4 Replies

Replies have been turned off for this discussion
  • Anonymous's avatar
    Anonymous

    I've been trying to solve this and one way that's kinda working is to search for the "Oculus.VR" assembly definition file. If it is present in the project I add a custom define to the build so that my Oculus-specific code gets compiled.

     

    string[] assets = AssetDatabase.FindAssets($"Oculus.VR t:AsmDef");

     

    This returns an array of guids. You can turn them back into file paths and make sure that it's the right file and it's in the expected location. You can also do further searches for scripts to make sure that it's not a really old integration.