Please support for .NET Standard 2.0
I am using Unity and downloaded this package through NuGet for Unity. Unfortunately, the NuGet package from this repository only contains a _._ file within the netstandard2.0 folder, indicating that actual support for .NET Standard 2.0 might be missing.
Could you please provide proper support for .NET Standard 2.0 to enhance compatibility with Unity?
Thank you!
Unity's .NET Standard 2.0 API doesn't support dynamic code generation, afaik. For Unity use HarmonyX it is, to quote the readme, "a fork of Harmony 2 that specializes on support for games and game modding frameworks." It is powered by MonoMod and specifically made to be used with Unity and is used by both big Unity Mod loaders BepInEx & MelonLoader.
Harmony's implementations depend on the specific runtime. As such it can't provide an implementation for netstandard. However, it does provide a reference assembly for netstandard code to compile against - but the right runtime assembly has to be provided for execution.
If you need more information about how to get Harmony running in a NetStandard runtime, please visit our discord. I’ll close this issue for now.