Giter Site home page Giter Site logo

MonoMod

MonoMod Discord General purpose .NET assembly modding "basework", powered by cecil.
MIT-licensed.

Build status Deployment status

GitHub: All NuGet: Patcher NuGet: Utils NuGet: RuntimeDetour NuGet: HookGen
GitHub releases Core Utils RuntimeDetour HookGen
Version Version Version Version Version

... or download fresh build artifacts for the last commit.

Sections

Special thanks to my patrons on Patreon:


Introduction

MonoMod is a modding "basework" (base tools + framework).
Mods / mod loaders for the following games are already using it in one way or another:

It consists of the following modular components:

  • MonoMod.Patcher: The ahead-of-time MonoMod patcher and relinker.
  • MonoMod.Utils: Utilities and helpers that not only benefit MonoMod, but also mods in general. It contains classes such as PlatformDetection, FastReflectionHelper, DynamicMethodHelper, DynamicMethodDefinition, DynDll and the ModInterop namespace.
  • MonoMod.DebugIL: Enable IL-level debugging of third-party assemblies in Visual Studio / MonoDevelop.
  • MonoMod.Core: The core upon which runtime method detouring is built.
  • MonoMod.RuntimeDetour: A flexible and easily extensible runtime detouring library, supporting x86/x86_64 on .NET Framework, .NET Core, and Mono.
  • MonoMod.RuntimeDetour.HookGen: A utility to generate a "hook helper .dll" for any IL assembly. This allows you to hook methods in runtime mods as if they were events. Built with MonoMod and RuntimeDetour.
  • MonoMod.Backports: A collection of BCL backports, enabling the use of many new language and library features, as far back as .NET Framework 3.5.

Why?

  • Cross-version compatibility, even with obfuscated assemblies.
  • Cross-platform compatibility, even if the game uses another engine (f.e. Celeste uses XNA on Windows, FNA on macOS and Linux).
  • Use language features which otherwise wouldn't be supported (f.e. C# 7 in Unity 4.3).
  • Patch on the player's machine with a basic mod installer. No need to pre-patch, no redistribution of game data, no copyright violations.
  • With HookGen, runtime hooks are as simple as On.Namespace.Type.Method += (orig, a, b, c) => { /* ... */ }
  • With HookGen IL, you can manipulate IL at runtime and even inline C# delegate calls between instructions.
  • Modularity allows you to mix and match. Use only what you need!

Debugging mods that use MonoMod

See Debugging.

MonoMod's Projects

monomod icon monomod

C# modding swiss army knife, powered by cecil.

monomod.common icon monomod.common

Common code used by MonoMod and other .NET modding libraries. Not to be confused with MonoMod.Utils (for mods).

monomod.github.io icon monomod.github.io

Repository housing the DocFX "project" and built web documentation via gh-pages for MonoMod.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.