Skip to content

Creating Character Modpacks

nikkiwritescode edited this page Dec 7, 2024 · 11 revisions

Written by nikkiwritescode

Table of Contents

Summary

This guide covers the process of taking a Fortune Street-compatible custom character and making a CSMM-compatible modpack from it. The process is not incredibly complex, but it's also not incredibly intuitive. No tools exist to assist with this, so it is a manual process for now.

Note

Please note that this is NOT a guide for creating characters. Several Custom Street members have discussed writing such a guide, so when that happens, this document will be updated to link to it.

Warning

Character modpacks are NOT compatible with versions of CSMM below 7.1.0.

Commonly-Used Terms

  • <character_code> = three-letter code of the character whose slot you are replacing. (e.g. snd = Stella)
  • <character_name> = the human-readable name of the character you are importing. (e.g. Rosalina)

Steps

The first step is to grab the character modpack template. There are a number of edits that must be made in order to create a usable character modpack, which are as follows:

Rename files

  1. Rename the character_<character_name>.py and character_<character_name>.json files with the human-readable name of the character you are importing. (e.g. character_rosalina.py and character_rosalina.json)

The chara subdirectory

  1. Copy your character's .brres model to the chara subdirectory, changing its name to ch_<nt or dq>_<character_code>.brres. (e.g ch_dq_snd.brres)

The game subdirectory

  1. Copy your character's icon, in .png format, to the game/mg_darts.brres subdirectory, and change its name to dart01_<character_code>1.png. (e.g. dart01_snd1.png)
  2. Copy your character's icon, in .png format, to the game/ui_game_f_<character_code>.arc subdirectory, and change its name to facewdw_<character_code>1.png. Be sure to also change the name of the subdirectory to include the same character code, as well. (e.g. facewdw_snd1.png and ui_game_f_snd.arc)

Modifying manifest.json

  1. Open manifest.json and update all the instances of <character_name> and <character_code> as described previously. Update the last_updated key to today's date in YYYY/MM/DD format, as well. Also, replace <character to replace> with the human-readable name of the character this mod should replace. (e.g. Stella)

Modifying modlist.txt

  1. Open modlist.txt and update the +character_<character_code> line with the human-readable name of the character you are importing, in lowercase. (e.g. +character_rosalina)

Modifying character_<character_name>.json

  1. Open character_<character_name>.json, and update <character_code> and <nt_or_dq> accordingly. (e.g. chara/ch_dq_snd.brres and files/chara/ch_dq_snd.brres)

Modifying character_<character_name>.py

  1. Open character_<character_name>.py. There will be several items in here that we will need to modify.
UI messages
  • UI_MSGS is in the format of CSV line number: "text of line", so make sure to cross-reference with the dialogue ui_message.<language>.csv file to ensure you are editing the right lines. At a minimum, you will want to change the character name and description lines. (Each language has the same line numbers, so you only need to reference one of the files.)
Character's primary color
  • When you see a line similar to mainDol.seek(mapper.boomToFileAddress(0x80000000), modify the address (beginning in 0x8000) and the value on the next line with the character color data in hexadecimal format.
  • The address to use is the Boom Street Virtual Address, prefixed with 0x. If you have a five-digit file address, use the Fortune Street Modding Address Calculator to find the correct value.
  • When updating the write value, be sure to change any spaces to \x. Place \x between each byte, following the format the template uses. (e.g. \x00\x01\x02\x03)
The remaining items in the Python file
  • Modify the remaining <character_code> and <character_name> instances, being sure to change anything with a # MODIFY THIS comment near it. You can remove the comments once done.

Troubleshooting

Caution

  • MAKE ABSOLUTELY CERTAIN that you are using the latest version of CSMM. Character modpacks are NOT COMPATIBLE with program versions below 7.1.0 and will cause CSMM to crash.
  • Be sure the entry in modlist.txt matches "+" followed by the name of the .json and .py files, minus the file extensions. (e.g. +character_rosalina)
  • Make sure that if you remove one of UI_MSGS or UI_MSGS_ALL, that you leave braces behind. Otherwise CSMM will likely crash, as leaving the equals sign hanging is invalid in the Python language. (e.g. UI_MSGS = {} )
  • Be sure absolutely everything that has a # MODIFY THIS comment near it in character_<character_name>.py gets modified. If you don't, the mod won't work, or worse...CSMM may crash.
  • Make sure to remove any brackets ( <> ) from the various filename entries.

Conclusion

Happy modding!! If you need further help with this, feel free to drop a message in the #modding-general, or #modding-issues channels of the Custom Street Discord server, depending on the nature of your question.