Skip to main content
April 16, 2021

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!

This topic has been closed for replies.

4 replies

New Participant
June 21, 2021

I second this.

June 21, 2021

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.

New Participant
June 21, 2021

Why not just get the assembly from the domain?