Closed yangboyd closed 6 months ago
Debug Log:
IL_0000: ldc.i4 0 IL_0005: stloc 1 (System.Boolean) IL_0009: ldc.i4.1 IL_000A: stloc 1 (System.Boolean) IL_000E: ldloc 1 (System.Boolean) IL_0012: brfalse => Label1
Refer #574 Use AccessTools.GetDeclaredConstructors()
Windows .Net 4.7 32bit Harmony 2
Hook a constructor, get exception.
hook exception: System.Exception: Cannot get result from void method System.Void loader.ILReader::.ctor(System.Reflection.MethodBase method, System.Byte[] code) 在 HarmonyLib.MethodPatcher.EmitCallParameter(MethodInfo patch, Dictionaryb__0(MethodInfo fix)
在 HarmonyLib.CollectionExtensions.Do[T](IEnumerable
2 variables, LocalBuilder runOriginalVariable, Boolean allowFirsParamPassthrough, LocalBuilder& tmpObjectVar, List
1 tmpBoxVars) 在 HarmonyLib.MethodPatcher.<>c__DisplayClass35_0.1 sequence, Action
1 action) 在 HarmonyLib.MethodPatcher.AddPrefixes(Dictionary2 variables, LocalBuilder runOriginalVariable) 在 HarmonyLib.MethodPatcher.CreateReplacement(Dictionary
2& finalInstructions) 在 HarmonyLib.PatchFunctions.UpdateWrapper(MethodBase original, PatchInfo patchInfo) 在 HarmonyLib.PatchProcessor.Patch() 在 HarmonyLib.Harmony.Patch(MethodBase original, HarmonyMethod prefix, HarmonyMethod postfix, HarmonyMethod transpiler, HarmonyMethod finalizer)