PatcherContext Class
Definition
Section titled “Definition”Context provided to patcher plugins from the associated patcher engine.
public class PatcherContext
Inheritance object
Properties
Section titled “Properties”AvailableAssemblies
Section titled “AvailableAssemblies”Contains a list of assemblies that will be patched and loaded into the runtime.
The dictionary has the name of the file, without any directories. These are used by the dumping functionality, and as such, these are also required to be unique. They do not have to be exactly the same as the real filename, however they have to be mapped deterministically.
Order is not respected, as it will be sorted by dependencies.
public Dictionary<string, AssemblyDefinition> AvailableAssemblies { get; }
AvailableAssembliesPaths
Section titled “AvailableAssembliesPaths”Contains a mapping of available assembly name to their original filenames.
public Dictionary<string, string> AvailableAssembliesPaths { get; }
LoadedAssemblies
Section titled “LoadedAssemblies”Contains a dictionary of assemblies that have been loaded as part of executing this assembly patcher.
The key is the same key as used in [LoadedAssemblies](../bepinex.preloader.core.patching.patchercontext/#loadedassemblies/), while the value is the actual assembly itself.
public Dictionary<string, Assembly> LoadedAssemblies { get; }
PatcherPlugins
Section titled “PatcherPlugins”A list of plugins that will be initialized and executed, in the order of the list.
public List<BasePatcher> PatcherPlugins { get; }
PatchDefinitions
Section titled “PatchDefinitions”A list of individual patches that AssemblyPatcher will execute, generated by parsing PatcherPlugins.
public List<PatchDefinition> PatchDefinitions { get; }
DumpedAssembliesPath
Section titled “DumpedAssembliesPath”public string DumpedAssembliesPath { get; }