Back to Harmony

Class ReversePatcher

docs/api/HarmonyLib.ReversePatcher.html

2.4.2.01.3 KB
Original Source

Class ReversePatcher

A reverse patcher

Inheritance

System.Object

ReversePatcher

Namespace : HarmonyLib
Assembly : 0Harmony.dll
Syntax
public class ReversePatcher

Constructors

ReversePatcher(Harmony, MethodBase, HarmonyMethod)

Creates a reverse patcher

Declaration
public ReversePatcher(Harmony instance, MethodBase original, HarmonyMethod standin)
Parameters
TypeNameDescription
Harmonyinstance

The Harmony instance

| | System.Reflection.MethodBase | original |

The original method/constructor

| | HarmonyMethod | standin |

Your stand-in stub method as HarmonyMethod

|

Methods

Patch(HarmonyReversePatchType)

Applies the patch

Declaration
public MethodInfo Patch(HarmonyReversePatchType type = HarmonyReversePatchType.Original)
Parameters
TypeNameDescription
HarmonyReversePatchTypetype

The type of patch, see HarmonyReversePatchType

|

Returns
TypeDescription
System.Reflection.MethodInfo

The generated replacement method

|