Skip to content

Instantly share code, notes, and snippets.

View JaXt0r's full-sized avatar

JaXt0r

View GitHub Profile
@EliteMasterEric
EliteMasterEric / Eric's EZ Guide to Harmony Patches.md
Created August 16, 2025 22:14
A guide to creating Prefix and Postfix patches in Harmony, for beginner Unity modders.

Introduction to BepInEx

(If you understand how BepInEx works and what it does, you can skip this and go to the next section.)

Modding Unity games is pretty standardized in 2025. In general, you have to create your mod code in C#, build it into a DLL file, then convince the game to execute your code.

There are two ways of doing this. The first is if the game has a mod loader built in, you just have to create and install mods based on their instructions. Games that work like this include Rimworld and Oxygen Not Included, and games that work like this generally have Steam Workshop support or some other standard way of distributing mods.

The other way is that if the game doesn't natively support mods, you can use BepInEx. BepInEx is a modloader, similar to Fabric for Minecraft. BepInEx works by placing a winhttp.dll file in your game folder, which does all the same things as the winhttp.dll file in your System32 folder, but it also tells it to load the code in the BepInEx DLL. From there, BepInEx can de

Turning a release build into a debug build

Requirements

Type Name Developer Price License Download Website
Decompiler/IL Editor dnSpy 0xd4d Open source GPL v3 https://ci.appveyor.com/project/0xd4d/dnspy/branch/master/artifacts GitHub
Decompiler dotPeek JetBrains Free Commercial https://www.jetbrains.com/decompiler/download/ Official Website
Deobfuscator de4dot 0xd4d Open source GPL v3 https://ci.appveyor.com/project/0xd4d/de4dot/branch/master/artifacts GitHub
@jbevain
jbevain / README.md
Last active December 5, 2025 20:37
pdb2mdb for Visual Studio 2015

The Visual Studio Tools for Unity are able to convert .NET debug symbol files (namely pdb files) to debug symbols files that are understood by Unity's scripting engine (namely .dll.mdb files) when importing both the .dll and the .pdb in the Assets folder.

If you prefer to handle the conversion yourself you need to call a tool named pdb2mdb on the .dll associated with the .pdb:

pdb2mdb MyLibrary.dll

Will produce a MyLibrary.dll.mdb usable on Unity if MyLibrary.pdb is present.

@myusuf3
myusuf3 / delete_git_submodule.md
Created November 3, 2014 17:36
How effectively delete a git submodule.

To remove a submodule you need to:

  • Delete the relevant section from the .gitmodules file.
  • Stage the .gitmodules changes git add .gitmodules
  • Delete the relevant section from .git/config.
  • Run git rm --cached path_to_submodule (no trailing slash).
  • Run rm -rf .git/modules/path_to_submodule (no trailing slash).
  • Commit git commit -m "Removed submodule "
  • Delete the now untracked submodule files rm -rf path_to_submodule
@mikezila
mikezila / TGALoader.cs
Created April 12, 2014 21:13
TGA Loader for Unity3D
// This was made by aaro4130 on the Unity forums. Thanks boss!
// It's been optimized and slimmed down for the purpose of loading Quake 3 TGA textures from memory streams.
using System;
using System.IO;
using UnityEngine;
public static class TGALoader
{