steamvr_unity_plugin icon indicating copy to clipboard operation
steamvr_unity_plugin copied to clipboard

Fix for Mac build

Open chilton opened this issue 7 years ago • 0 comments

Hi,

In file SteamVR_Input_PostProcessBuild.cs ...

BEFORE this line (around line 21)... SteamVR_Input.actionFile.CopyFilesToPath(buildPath, overwrite);

Add the following: #if UNITY_STANDALONE_OSX buildPath = pathToBuiltProject; #endif

This changes the path so that the hand controller binding files are placed in the right folder for the Mac build, allowing the build process to correctly move the files, which in turn allows the hand controllers to work properly in your finished app.

Note: This still requires that the files exist in a non-standard location, which is at the root level inside the Mac app's package. I don't know if this will prevent the app from being sold on the Mac App Store. The correct location for these files is in the Resources folder of the Mac app, but that might require further changes to where SteamVR looks for these files during app execution.

This solution gets you a working app though.

chilton avatar Apr 04 '19 13:04 chilton