-
Notifications
You must be signed in to change notification settings - Fork 47
Replacing Base Game Text & Images
Before following any guide on this page, make sure you have create a template by following the steps in Setup first. If you only want to replace assets, use the Empty Slay the Spire 2 Mod template.
- Open up your project folder in the godot editor
- If using rider, you can click this button in the top right (If it doesn't appear, make sure your godot path in
Directory.Build.propsis correct)
- If using rider, you can click this button in the top right (If it doesn't appear, make sure your godot path in
-
Place your custom image(s) somewhere in your project folder (in
ModName/imagesis a good place for them)- Image dimensions should be a multiple of 500x380 (e.g. 250x190 or 1000x760)
-
Open your custom image in the File Editor pane of the godot editor and double click it to open it up in the inspector panel on the right. Find and copy the
Load Pathfield
-
Recreate the same folder structure as the base game card you want to replace the art of
- Example:
images/atlases/card_atlas.sprites/ironclad/strike_ironclad.tres - Look at Extracting Assets and Text to see the base game folder structure for yourself
- Example:
-
In the godot editor, right click >
Create New>Resource> selectCompressedTexture2D
- Double click on the resource (
.tresfile) you created in a previous step, and paste the path you copied earlier into itsLoad Pathfield
- Finally, publish your project, and your changes should appear in-game
The newest template version tries to minimize build/publish time by checking if there are any changes in the ModName folder and only creates the pck if there are. You don't want this because you need to place these files outside of that folder. To change this open your .csproj file (the file with the green icon that says C# in it), scroll to the bottom and in the line that says
<Target Name="GodotPublish"...remove the following:
and '$(IsInnerGodotExport)' != 'true'" Inputs="@(GodotResourceFiles)" Outputs="$(ModsPath)$(MSBuildProjectName)/$(MSBuildProjectName).pckSince mods are loaded after the base game, using the same localization keys as the base game will cause your mod to replace base game localization.
For example, creating a file at ModName/localization/eng/cards.json with the following contents will change the title and description of ironclad's starter strike:
{
"STRIKE_IRONCLAD.title": "Strike 2",
"STRIKE_IRONCLAD.description": "Electric Boogaloo"
}The same pattern can be used to change any text in the base-game, look at Extracting Assets and Text to get a reference of the existing localization.