This is a coding mod template for The Long Dark by Hinterland Games.
- Download this folder.
- Rename
ModTemplate.csproj
to the name of the mod. - Install .NET 6.
- Install Visual Studio.
- Run Visual Studio. Click on
Open a project or solution
. Select the renamedModTemplate.csproj
file. - Create a new class and inherit it from
MelonLoader.MelonMod
. - Edit
AssemblyInfo.cs
with your mod details. - In the
Build
menu, click onBuild Solution
. - If compilation succeeds, your mod will be in a sub folder, typically
bin/Debug/net6.0/
orbin/Release/net6.0
. - Copy the compiled mod to your
Mods
folder and run the game.
- Release builds run faster than Debug builds, but Debug builds show better stack traces when an error occurs.
- If at any point, Visual Studio asks where to save the solution, save it next to the
csproj
file. - If you have duplicate mods in your
Mods
folder, MelonLoader will error.
Do not post issues asking how to use this. There are Discord servers for asking these kinds of questions:
Do not ping me on Discord either, especially not in direct messages.