SlugBase registers a custom character from a JSON object under a mod’s slugbase directory. The object needs id, name, and description. SlugBase is an optional dependency for Rain World mods, but it is required for this character definition route. The current released SlugBase package has not been checked against the pinned source used here, commit dac343359d0f6e311de9f89345954f9ad2b25f3e.
The JSON filename does not provide the character’s identity and does not need to be globally unique. JsonRegistry reads the id property and claims a SlugcatStats.Name with that value. SlugBaseCharacter stores the claimed value in Name, reads name into DisplayName, and reads description into Description.
| Field | Meaning |
|---|---|
id | Technical identity used by code, saves, and character specific content |
name | Display name shown in character selection |
description | Description shown in character selection |
Choose a stable id. Registration fails when another registered character already owns the same value. Changing it later creates a different character identity from the game’s point of view, so existing campaign data should not be assumed to follow the renamed character. Display text belongs in name and description, not in the identifier.
This minimal original example can be saved as a JSON file directly under the mod’s slugbase directory:
{
"id": "LanternWren",
"name": "The Lantern Wren",
"description": "A traveler following the glow of old shelters."
}The object registers a character definition. It does not supply art, rooms, dialogue, save flags, or custom mechanics. See Atlases and shaders for loaded art assets and Campaign world state for campaign location and world selection.
Add declared features
An optional features object holds values recognized by SlugBase’s feature registry. Unknown feature names cause JSON loading to fail in the pinned source. Four campaign fields have direct documentation and matching registrations in Features.cs:
| Feature | Accepted value | Use |
|---|---|---|
karma | integer | Initial karma |
karma_cap | integer | Initial karma cap |
start_room | string or string array | Starting room, with array entries tried in order |
world_state | string or string array | Timeline priorities for world content |
start_room requires at least one value. A list provides fallback room names if an earlier room is absent. Presence alone does not establish that a room is a suitable story start or shelter. Check the room and its region content as described in Rooms and regions.
world_state accepts SlugcatStats.Timeline values. Its list controls world inheritance and is separate from the character’s SlugcatStats.Name. Campaign world state covers that distinction and the priority rules.
The maintainer guide says some color and stat edits can appear after changing JSON without recompiling or restarting. It identifies karma and start_room as values checked less often. Treat changes to those fields as new campaign setup data and restart the relevant flow when checking them.
Keep character data separate from saved facts
Feature values describe defaults and behavior selectors for the character. A fact learned during one campaign, such as whether the player met an oracle, belongs in save data. Campaign save data describes the available persistence scopes and SlugBase’s extension API. Player choices that apply beyond one campaign belong in mod configuration instead. See Remix settings.
These examples were checked against source only. They were not compiled or run in Rain World, and they do not establish compatibility with the current SlugBase release.