A tiny dll loader for Unity games
Find a file
2026-07-03 08:22:10 +02:00
.cargo init 2026-06-29 22:09:04 +02:00
src allow plain loader builds on windows-gnu 2026-07-03 08:22:10 +02:00
.gitignore init 2026-06-29 22:09:04 +02:00
build.rs allow plain loader builds on windows-gnu 2026-07-03 08:22:10 +02:00
Cargo.lock init 2026-06-29 22:09:04 +02:00
Cargo.toml init 2026-06-29 22:09:04 +02:00
LICENSE init 2026-06-29 22:09:04 +02:00
README.md init 2026-06-29 22:09:04 +02:00
rust-toolchain.toml init 2026-06-29 22:09:04 +02:00
rustfmt.toml init 2026-06-29 22:09:04 +02:00

Unity DLL Loader

A tiny dll loader for Unity games.

By default it builds a version.dll proxy: it forwards the exports to the real Windows version.dll, then loads every .dll found in the dlls folder next to the game executable.

Layout

Game.exe
version.dll
dlls/
  a_dll.dll
  another_dll.dll
  yet_another_dll.dll

DLLs are loaded in deterministic filename order.

Building

Build the default proxy DLL:

cargo build --release

Output:

target/x86_64-pc-windows-msvc/release/version.dll

Build a plain loader DLL without the version.dll proxy exports (in case the game just doesn't load it by default and you want to inject it in any other way):

cargo build --release --no-default-features

Output:

target/x86_64-pc-windows-msvc/release/dll_loader.dll

If you are cross-compiling and C:\Windows\System32\version.dll is not available at build time, point PROXY_DLL_PATH at a copy of it:

PROXY_DLL_PATH=/windows/version.dll cargo build --release

Notes

  • It skips loading DLLs when running inside UnityCrashHandler64.exe (because it also loads the version.dll).
  • Long paths are supported up to the Windows UTF-16 path limit.