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

Use HarmonyX instead #26

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Source/ExampleMod/ExampleMod.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="0Harmony, Version=2.0.4.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\Lib.Harmony.2.0.4\lib\net45\0Harmony.dll</HintPath>
<Reference Include="0Harmony, Version=2.9.0.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\HarmonyX.2.9.0\lib\net45\0Harmony.dll</HintPath>
</Reference>
</ItemGroup>

Expand Down
2 changes: 1 addition & 1 deletion Source/ExampleMod/packages.config
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="Lib.Harmony" version="2.0.4" targetFramework="net45" />
<package id="HarmonyX" version="2.9.0" targetFramework="net45" />
</packages>
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public IEnumerator Load()
/// <inheritdoc />
public void Shutdown()
{
_harmony.UnpatchAll();
_harmony.UnpatchSelf();
_harmony = null;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ public void Register(PluginWhitelist whitelist)
// Do not allow for transpile for now TODO: We have to figure something out
typeof(HarmonyLib.HarmonyTranspiler),
typeof(HarmonyLib.Transpilers),
typeof(HarmonyLib.FileLog),
typeof(HarmonyLib.Memory)
typeof(HarmonyLib.FileLog)//,
//typeof(HarmonyLib.Memory)
);
whitelist.WhitelistTypesNamespaces(
typeof(HarmonyLib.Harmony) // Just allow everything
Expand Down
4 changes: 2 additions & 2 deletions Source/Stationeers.Addons/Stationeers.Addons.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<ItemGroup>
<Reference Include="0Harmony, Version=2.0.4.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\Lib.Harmony.2.0.4\lib\net45\0Harmony.dll</HintPath>
<Reference Include="0Harmony, Version=2.9.0.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\HarmonyX.2.9.0\lib\net45\0Harmony.dll</HintPath>
</Reference>
<Reference Include="Microsoft.CodeAnalysis, Version=3.8.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.CodeAnalysis.Common.3.8.0\lib\netstandard2.0\Microsoft.CodeAnalysis.dll</HintPath>
Expand Down
2 changes: 1 addition & 1 deletion Source/Stationeers.Addons/packages.config
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="Lib.Harmony" version="2.0.4" targetFramework="net45" />
<package id="HarmonyX" version="2.9.0" targetFramework="net45" />
<package id="Microsoft.CodeAnalysis.Analyzers" version="3.0.0" targetFramework="net471" developmentDependency="true" />
<package id="Microsoft.CodeAnalysis.CSharp" version="3.8.0" targetFramework="net471" />
<package id="Microsoft.CodeAnalysis.Common" version="3.8.0" targetFramework="net471" />
Expand Down