A clean cheat template for Unity games that run on mono.
// Change these 3 values:
internal const string Name = "YOUR_CHEAT_NAME";
internal static Version Version = new(1, 0, 0);
internal const string GUID = "com.yourname.cheat";// Add new variables here:
public bool b_YourToggle = true;
public float f_YourValue = 50f;// Create new class:
internal class YourTab : CheatMenuTab
{
internal override string TabName => "Your Tab";
internal override uint TabIndex => 1;
internal override void OnGUI()
{
UI.Checkbox(ref b_YourToggle, "Enable Feature");
UI.FloatSlider(ref f_YourValue, 0, 100, "Slider");
}
}internal sealed class YourCheat : ISingleton
{
internal void Update() { /* Game logic */ }
internal void OnGUI() { /* ESP/Drawing */ }
}public void Update()
{
Singleton<YourCheat>.Instance.Update(); // Add this
}You'll need to find out what .NET version the game uses.
Check the game's Assembly-CSharp.dll with a tool like dnSpy or ILSpy.
<TargetFramework>net48</TargetFramework> <!-- Change to match game's .NET version -->Add required DLLs:
src/
├── References/
│ ├── Game/ # Game-specific DLLs (Assembly-CSharp.dll, etc.)
│ ├── Unity/ # Unity engine DLLs (UnityEngine.dll, UnityEngine.CoreModule.dll, etc.)
│ └── Dependencies/ # Dependency DLLs that aren't in the original game (0Harmony.dll, etc.)
Track all instances of specific MonoBehaviour types:
// In your component's Awake():
CatchMono<PlayerController>.Register(this);
// In OnDestroy():
CatchMono<PlayerController>.Unregister(this);
// Access all instances:
foreach (var player in CatchMono<PlayerController>.AllMonos)
{
// Do something with each player
}Embed external DLLs in your cheat:
- Place DLLs in
Resources/Dependencies/folder - Add to
dependencies.json:
{
"Dependencies": [
"0Harmony.dll",
"MonoMod.RuntimeDetour.dll"
]
}- DLLs auto-load at runtime
One-click build and injection:
Features:
- Auto-builds your project
- Injects DLL into running game process
- Downloads SharpMonoInjector if missing
- Configurable settings
Setup:
# Edit these lines in injector.bat:
set project_name=UnityCheatTemplate # Your project name
set game_name=GameName # Game's .exe name (without .exe)Usage:
- Run
injector.bat - Select
[1] Inject DLL into Process - It builds your cheat and injects it automatically
- CatchMono - Track all instances of MonoBehaviour types
- Singleton - Global access:
Singleton<YourClass>.Instance - UI Utilities - Pre-made checkboxes, sliders, color pickers
- ESP System -
RenderEspElement()for boxes and tracers - Hotkeys -
KeyBinder.Bind()with modifier keys - Reflection - Access private fields/methods safely
- Dependency Injection - Embed external DLLs
- Auto Injector - One-click build & inject
src/
├── Data/ - Settings & JSON
├── Extensions/ - Reflection tools
├── Modules/
│ ├── Cheats/ - ESP, Trigger, etc.
│ └── Menu/ - UI system
├── References/ # ADD REQUIRED DLLS HERE
│ ├── Game/ # Assembly-CSharp.dll, GameAssembly.dll
│ └── Unity/ # UnityEngine.dll, UnityEditor.dll
├── Resources/
│ └── Dependencies/ # Place external DLLs here
└── injector.bat # Build & inject script
Get started:
- Find game's .NET version (check Assembly-CSharp.dll)
- Update .csproj with correct
TargetFramework - Add required DLLs to References/Game and References/Unity
- Change
CheatInfo.cs - Add settings in
SettingsFile.cs - Create menu tabs
- Add cheat logic
- Run
injector.bat