Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Installation on macOS makes checks for Windows paths before calling GetOS() #193

Open
tercenya opened this issue Sep 20, 2020 · 4 comments

Comments

@tercenya
Copy link

Describe the problem
I downloaded QModManager 4.0.2.3-201-4-0-2-3-1600476097.exe, installed it on a Windows VM, copied the latest BepInEx folder over to my Mac (10.15.6). While attempting to run mono QModManager.exe, I kept getting a "Could not find Managed directory" error, no matter where I put the BepInEx directory.

A quick survey of the code

string gameRootDirectory = Path.Combine(Environment.CurrentDirectory, "../../..");
string snManagedDirectory = Path.Combine(gameRootDirectory, "Subnautica_Data", "Managed");
shows that the installer is looking for ../../../Subnautica_Data/Managed, and can fail with the above error before it calls GetOS
os = GetOS();
to specialize directory names. Unfortunately the directory in question in macOS is ~/Library/ApplicationSupport/Steam/steamapps/common/Subnautica/Subnautica.app/Contents/Resources/Data/Managed, so the check for the managed directory always fails.

I also couldn't run the QModManager.exe with out importing the BepInEx dlls to the local folder since the relative paths require me to execute the file from its own directory?

Workaround
Since the first check expected the Data folder to 3 dirctories down, I placed the BepInEx folder in ~/Library/ApplicationSupport/Steam/steamapps/common/Subnautica/Subnautica.app/Contents/Resources and ran:

cd ~/Library/ApplicationSupport/Steam/steamapps/common/Subnautica/Subnautica.app/Contents/Resources
ln -s Data Subnautica_Data
cd BepInEx/patchers/QModManager
ln -s ../../core/* .
mono QModManager.exe
@silvervirus
Copy link

That's because that folder is within the subnautica.app under resources I believe

@slheavner
Copy link

slheavner commented Oct 7, 2020

here's a script that is working for me, and it avoids using the installer
https://gist.github.com/slheavner/7b95d9e652b8b9df7b5f5b72c50754b3

Edit:
adding notes of what it does

  • fetch BepInEx and install per instructions from their site.
  • copy required dlls/files to plugins and patchers folders of BepInEx
  • instruct the user to add the appropriate luanch options for subnuatica in steam, as per BepInEx's website

@PrimeSonic
Copy link
Member

@tobeyStraitjacket Take a look at this when you can.

@toebeann
Copy link
Contributor

toebeann commented Oct 8, 2020

Ah, interesting. Ty for this info I will get this fixed soon

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants