Getting started
This section takes you from nothing to a mod you can share. You do not need to have made a mod before. Each page covers one job.
Install the game’s mod tools and the framework first, using the install page. Then start with Your first mod. It builds a small mod and shows a hint box and a log line in about five minutes. Every later page uses the same project, so keep it. To try a page’s code, replace the code in Plugin.cs with the code on that page and build again. The build writes over the same DLL, so you do not get duplicate mods.
Read the pages in this order the first time:
- Your first mod: make, build and run a mod.
- Logging: write notes to your mod’s log file.
- Config: add settings players can change.
- Keybinds: react to a key.
- Using events: react to the game clock, saves and levels.
- Save data: remember things per save game.
- Patching: change a game method, as a last resort.
- Packaging: make a zip to share.
- When things run: the order of the framework’s calls, and what is safe at each one.
After that, the Cookbook has short recipes for common jobs, such as giving an item or paying the player. When your mod works, read Using the framework alongside other mods before you share it.