-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #226 from SubnauticaModding/Dev
QMM 4.1.3
- Loading branch information
Showing
25 changed files
with
507 additions
and
107 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
4.1.2 | ||
4.1.3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# Building on OSX | ||
|
||
## Preparation | ||
|
||
### Prepare Solution | ||
* Open `QModManager.sln` with Visual Code to initialize packages | ||
|
||
### Create Publicized Assemblies | ||
* Follow instructions at the [SMLHelper GitHub page](https://github.com/SubnauticaModding/SMLHelper) | ||
* Download [AssemblyPublicizer.zip](https://github.com/CabbageCrow/AssemblyPublicizer/releases/download/v1.1.0/AssemblyPublicizer.zip) and extract to `~/AssemblyPublicizer.exe` | ||
* Create publizised assemblies: | ||
* `cd "~/Library/Application Support/Steam/steamapps/common/SubnauticaZero/SubnauticaZero.app/Contents/Resources/Data/Managed"` | ||
* `mono ~/AssemblyPublicizer.exe -i Assembly-CSharp.dll` | ||
* `mono ~/AssemblyPublicizer.exe -i Assembly-CSharp-firstpass.dll` | ||
* Copy the dlls from `publicized_assemblies/` to `Dependencies/BZ.STABLE/` | ||
|
||
## Build | ||
* Create distribution package by running `MacOSX/build.sh` | ||
|
||
## Installation | ||
* Copy distribution package contents to `~/Library/Application Support/Steam/steamapps/common/SubnauticaZero` | ||
* Update Steam Launch options to `"/Users/username/Library/Application Support/Steam/steamapps/common/SubnauticaZero/QModManager.sh" %command%` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
#!/bin/bash | ||
|
||
# Variables | ||
CONFIGURATION="BZ.STABLE" | ||
VERSION="4.0.2.3" | ||
echo "[$CONFIGURATION]" | ||
|
||
# Clean up build and dist folder | ||
DEPS="./Dependencies" | ||
BUILD="./Build/$CONFIGURATION" | ||
DIST="./Build/MacOSX/$CONFIGURATION" | ||
rm -rf ./Build | ||
rm -rf $DIST | ||
mkdir -p $DIST | ||
mkdir -p "./$DIST/BepInEx/patchers/QModManager/" | ||
mkdir -p "./$DIST/BepInEx/plugins/QModManager/" | ||
mkdir -p "./$DIST/doorstop_libs" | ||
|
||
# Download QModManager.exe | ||
echo "~> downloading QModManager.exe" | ||
wget -q -O "$DIST/QModManager.zip" "https://github.com/SubnauticaModding/QModManager/archive/refs/tags/v$VERSION.zip" | ||
unzip -qq "$DIST/QModManager.zip" -d "$DIST/QModManager" | ||
cp "$DIST/QModManager/QModManager-$VERSION/Build/QModManager.exe" "./$DIST/BepInEx/patchers/QModManager/QModManager.exe" | ||
cp "$DIST/QModManager/QModManager-$VERSION/Build/QModManager.exe.config" "./$DIST/BepInEx/patchers/QModManager/QModManager.exe.config" | ||
rm "$DIST/QModManager.zip" | ||
rm -rf "$DIST/QModManager" | ||
|
||
# Download doorstop libs | ||
echo "~> downloading doorstop libs" | ||
wget -q -O "./$DIST/doorstop_libs/libdoorstop_x64.dylib" https://github.com/SphereII/DMTBridgeLoaderPlugin/raw/main/doorstop_libs/libdoorstop_x64.dylib | ||
wget -q -O "./$DIST/doorstop_libs/libdoorstop_x86.dylib" https://github.com/SphereII/DMTBridgeLoaderPlugin/raw/main/doorstop_libs/libdoorstop_x86.dylib | ||
|
||
# Build projects | ||
echo "~> building OculusNewtonsoftRedirect" | ||
msbuild ./OculusNewtonsoftRedirect/QModManager.OculusNewtonsoftRedirect.csproj -property:Configuration=$CONFIGURATION -verbosity:quiet 2>&1 > /dev/null | ||
echo "~> building QModManager" | ||
msbuild ./QModManager/QModManager.csproj -property:Configuration=$CONFIGURATION -verbosity:quiet 2>&1 > /dev/null | ||
echo "~> building UnityAudioFixer" | ||
msbuild ./UnityAudioFixer/QModManager.UnityAudioFixer.csproj -property:Configuration=$CONFIGURATION -verbosity:quiet 2>&1 > /dev/null | ||
echo "~> building QModPluginGenerator" | ||
msbuild ./QModPluginEmulator/QModManager.QModPluginGenerator.csproj -property:Configuration=$CONFIGURATION -property:PostBuildEvent= -verbosity:quiet 2>&1 > /dev/null | ||
|
||
# Copy Build Files | ||
echo "~> creating distribution package" | ||
cp -r "$DEPS/BepInEx/BepInEx" "./$DIST" | ||
cp "$DEPS/BepInEx/doorstop_config.ini" "./$DIST" | ||
cp "$DEPS/BepInEx/winhttp.dll" "./$DIST" | ||
cp "$DEPS/cldb.dat" "./$DIST/BepInEx/patchers/QModManager/" | ||
cp "./packages/AssetsTools.NET.2.0.3/lib/net35/AssetsTools.NET.dll" "./$DIST/BepInEx/patchers/QModManager/" | ||
cp "$BUILD/QModManager.QModPluginGenerator.dll" "./$DIST/BepInEx/patchers/QModManager/" | ||
cp "$BUILD/QModManager.UnityAudioFixer.dll" "./$DIST/BepInEx/patchers/QModManager/" | ||
cp "$BUILD/QModManager.UnityAudioFixer.xml" "./$DIST/BepInEx/patchers/QModManager/" | ||
cp "$BUILD/QModInstaller.dll" "./$DIST/BepInEx/plugins/QModManager/" | ||
cp "$BUILD/QModInstaller.xml" "./$DIST/BepInEx/plugins/QModManager/" | ||
|
||
# Copy Build Files for SN.SABLE | ||
if [ "$CONFIGURATION" != "SN.STABLE" ]; then | ||
cp "$DEPS/Oculus.Newtonsoft.Json.dll" "./$DIST/BepInEx/patchers/QModManager/" | ||
cp "$BUILD/QModManager.OculusNewtonsoftRedirect.dll" "./$DIST/BepInEx/patchers/QModManager/" | ||
fi | ||
|
||
# Copy Launcher | ||
cp "./MacOSX/dist/QModManager.sh" "./$DIST/QModManager.sh" | ||
chmod +x "./$DIST/QModManager.sh" | ||
echo "~> distribution package created at $DIST" | ||
|
||
# Build Installer Package | ||
chmod -R 755 $DIST | ||
PKG_BUILD="./MacOSX/PKG.$CONFIGURATION" | ||
mkdir -p $PKG_BUILD | ||
pkgbuild --identifier org.QModManager.$VERSION --version $VERSION --install-location "/Library/Application Support/Steam/steamapps/common/SubnauticaZero" --root "$DIST" $PKG_BUILD/QModManager.pkg > /dev/null 2>&1 | ||
productbuild --distribution ./MacOSX/dist/Distribution --resources ./MacOSX/dist/Resources --package-path $PKG_BUILD "./Build/MacOSX/QModManager-$VERSION.$CONFIGURATION.pkg" > /dev/null 2>&1 | ||
rm -rf $PKG_BUILD | ||
echo "~> installer package created at Build/MacOSX/QModManager-$VERSION.$CONFIGURATION.pkg" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
<?xml version="1.0" encoding="utf-8" standalone="no"?> | ||
<installer-script minSpecVersion="1.000000"> | ||
<title>QModManager</title> | ||
<background mime-type="image/png" file="banner.png" scaling="proportional"/> | ||
<background-darkAqua mime-type="image/png" file="banner.png" scaling="proportional"/> | ||
<welcome file="welcome.html" mime-type="text/html" /> | ||
<conclusion file="conclusion.html" mime-type="text/html" /> | ||
<license file="LICENSE.html" mime-type="text/html"/> | ||
<options customize="never" allow-external-scripts="no"/> | ||
<domains enable_localSystem="false" /> | ||
<domains enable_anywhere="true" /> | ||
<domains enable_currentUserHome="true" /> | ||
<installation-check script="installCheck()"/> | ||
<script> | ||
function installCheck() { | ||
if (!(system.compareVersions(system.version.ProductVersion, '10.6.0') >= 0)) { | ||
my.result.title = 'Unable to install' | ||
my.result.message = 'QModManager requires Mac OS X 10.6 or later.' | ||
my.result.type = 'Fatal' | ||
return false | ||
} | ||
if (system.files.fileExistsAtPath('/Library/QModManager/4.0.2.3/')) { | ||
my.result.title = 'Previous Installation Detected' | ||
my.result.message = 'A previous installation of QModManager exists at /Library/QModManager/4.0.2.3/. This installer will remove the previous installation prior to installing. Please back up any data before proceeding.' | ||
my.result.type = 'Warning' | ||
return false | ||
} | ||
return true | ||
} | ||
</script> | ||
<choices-outline> | ||
<line choice="QModManager"/> | ||
</choices-outline> | ||
<choice id="QModManager" title="QModManager"> | ||
<pkg-ref id="QModManager.pkg"/> | ||
</choice> | ||
<pkg-ref id="QModManager.pkg" auth="Root">QModManager.pkg</pkg-ref> | ||
</installer-script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
#!/bin/sh | ||
EXECUTABLE_NAME="SubnauticaZero.app" | ||
|
||
export DOORSTOP_ENABLE=TRUE | ||
export DOORSTOP_INVOKE_DLL_PATH="${PWD}/BepInEx/core/BepInEx.Preloader.dll" | ||
|
||
ARCH="" | ||
EXECUTABLE_NAME=`basename "${EXECUTABLE_NAME}" .app` | ||
REAL_EXECUTABLE_NAME=`defaults read "${PWD}/${EXECUTABLE_NAME}.app/Contents/Info" CFBundleExecutable` | ||
EXECUTABLE_PATH="${PWD}/${EXECUTABLE_NAME}.app/Contents/MacOS/${REAL_EXECUTABLE_NAME}" | ||
EXECUTABLE_TYPE=`LD_PRELOAD="" file -b "${EXECUTABLE_PATH}"`; | ||
|
||
case $EXECUTABLE_TYPE in | ||
*64-bit*) | ||
arch="x64" | ||
;; | ||
*32-bit*|*i386*) | ||
arch="x86" | ||
;; | ||
*) | ||
echo "Cannot identify executable type (got ${EXECUTABLE_TYPE})!" | ||
echo "Please create an issue at https://github.com/BepInEx/BepInEx/issues." | ||
exit 1 | ||
;; | ||
esac | ||
|
||
DOORSTOP_LIBS="${PWD}/doorstop_libs" | ||
DOORSTOP_LIBNAME=libdoorstop_${arch}.dylib | ||
|
||
export LD_LIBRARY_PATH="${DOORSTOP_LIBS}":${LD_LIBRARY_PATH} | ||
export LD_PRELOAD=$DOORSTOP_LIBNAME:$LD_PRELOAD | ||
export DYLD_LIBRARY_PATH="${DOORSTOP_LIBS}" | ||
export DYLD_INSERT_LIBRARIES="${DOORSTOP_LIBS}/$DOORSTOP_LIBNAME" | ||
|
||
"${EXECUTABLE_PATH}" |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
|
||
<!DOCTYPE html> | ||
<html lang="en"> | ||
<head><meta charset="utf-8" /></head> | ||
<body> | ||
<div style="font-family: Helvetica; padding-left: 10px;" align="left"> | ||
<h3>QModManager</h3> | ||
<p style="color: #020202; font-size: 11px;">Thank you for installing QModManager.</p> | ||
<h5>Configure Steam</h5> | ||
<p style="color: #020202; font-size: 11px;">Set the Launch Options for Subnautica Below Zero to:</p> | ||
<code style="font-size: 11px;"> | ||
"/Users/{USERNAME}/Library/Application Support/Steam/steamapps/common/SubnauticaZero/QModManager.sh" %command% | ||
</code> | ||
</div> | ||
<div style="font-family: Helvetica; padding-left: 10px;" align="left"> | ||
<br/> | ||
<h5>Resources</h5> | ||
<p style="color: #020202; font-size: 11px;">Go through following links for additional information.</p> | ||
<ul> | ||
<li><a href="https://github.com/SubnauticaModding/QModManager" style="font-size: 11px;">GitHub Page</a></li> | ||
</ul> | ||
</div> | ||
<div style="font-family: Helvetica; padding-left: 10px;" align="left"><br /> | ||
<p style="color: #abb0b0; font-size: 10px;">Copyright © 2021 QModManager Inc. All rights reserved.</p> | ||
</div> | ||
</body> | ||
</html> |
Oops, something went wrong.