Repository navigation
Your First Project
If you want to migrate an existing project to use MoDot, please refer to Migrating project
To create a new project, download the latest nuget package that has the project templates for MoDot mods from here.
After downloading, run dotent new install <pacakge>.nupkg to install the templates.
You can now use Rider to create your project. Follow the steps outlined in the original templates wiki with the following changes:
In step 4:
- choose one of the MoDot templates.
In step 5:
- The property has been renamed to
<ModotPath>and needs to be pointed to a Modot executable. Additionally, the<ModotModsPath>property needs to be filled out. Provide the same path as<ModotPath>but replace the final executable withmods/.
In step 8:
- Before publishing, open
override.cfgand fill out both paths. You can add multiple pcks and dlls by separating entries with a,.
[!] Important
There are three configurations:
Debug,ExportDebugandExportRelease. Modot specifically requires theDebugversion of your files.The template is set up so that a build with
Debugwill not write to the games directory, but just Modots, while the other two do not write to Modots directory but the games.Keep this in mind for both, building (the hammer icon) and publishing.
From here on out you can follow the guide as written.
After closing and opening the project in Rider, the Godot plugin should properly work now. You can use the godot face symbol next to the build hammer to start the editor. Alternatively, two .NET Executable configurations should now be available. Editor starts the editor and Player launches directly to the editor-player.
Check your MainFile.cs and make sure the Godot bridge line is wrapped with these preprocessor directives:
#if !TOOLS
Godot.Bridge.ScriptManagerBridge.LookupScriptsInAssembly(System.Reflection.Assembly.GetExecutingAssembly());
#endif
Migrating a project is more manual work. And the specifics depend on when you created your project with the original templates, and wether you changed anything or not. So the following is not a step by step guide but more a list of TODOs.
Copy the content of project.godot from one provided by a template on the github
You want to copy the entire thing into your project.godot file. Then make sure replace ModTemplate with your project name where ever it appears.
Create override.cfg next to your project.godotfile. Copy this into it and adjust the paths:
[editor]
mounted_packs/paths=PackedStringArray("C:/Path/To/SlayTheSpire2.pck")
mounted_assemblies/paths=PackedStringArray("C:/Path/To/steamapps/common/Slay the Spire 2/data_sts2_windows_x86_64/sts2.dll")
Make sure your publishing and building only copy files into the MoDot directory when using Debug and only to the real game when using ExportDebug or ExportRelease
This wiki is still under construction, thank you for your patience