Skip to content

Translating map labels

Gong Xian edited this page Jul 1, 2022 · 18 revisions

Most strings for labels for map locations are written into 1ST_READ.BIN, while others are found in chapter script files.

Editing labels in 1ST_READ.BIN

The map labels that do not change throughout the game are located in 1ST_READ.BIN. Their properties are described in consecutive chunks of data.

Map label table locations

Address Description
8c2028b8 Les Chattes Noires
8c203590 City 1
8c203ddc City 2
8c2043a8 Bleumer Estate

Table entry format

This is an example found at 0x1928b8.

Offset Example value Description
0x0 00 00 00 ff Mask?
0x4 00 00 00 00 00
0x8 64 00 00 00 ID?
0xC 42 00 00 00 Label graphic width; default values are in multiples of 22 pixels per character
0x10 00 4c 22 8c Little-endian pointer to string; this one at 8c224c00 is "@fs22,22@fm24,0下町へ"
0x14 00 00 00 00 Floating point for X coordinate of hotspot location
0x18 9a 99 11 c1 Floating point for Y coordinate of hotspot location

The default strings change the text size to 22 and the character offset to 24. See the documentation on control codes.

To edit this label, write a new string into a free location, change the pointer to that location, and change the label graphic width accordingly.


  1. Use Demul to play the game until a map screen is reached. Save a state at this point.
  2. Point the in-game map cursor to a hotspot to reveal the label.
  3. Open the Demul process in Cheat Engine and open the Memory Viewer.
  4. In the Memory Viewer, navigate to the applicable memory region in the table above, minus 60000000, e.g. 2c2028e4 for the pointer in the table for the label "@fs22,22@fm24,0}ポーチ" in Les Chattes Noires.
  5. In Cheat Engine, change the pointer to the address of the new string in little-endian order, e.g. 00 0c da 8c. Changes will occur immediately.
    • If you have not yet updated the string, navigate to the destination of the new string, e.g. 2cda0c00 (0xc8d40 in SKFONT.CG), and paste the encoded string bytes into the memory viewer.
  6. The four bytes before the pointer are the label width. Select the first byte and use the + and - keys on the keyboard to adjust the label width until the text is centered. The graphic will change size to accommodate the width as it is updated.

Repeat these steps for each label in the current map. Note that some labels may have duplicate table entries, and some labels are not used and are instead defined in script files. The procedure below describes how to change these labels.

When all labels have been edited and centered in Cheat Engine, make the same changes to these bytes in Ghidra. Use the Byte Viewer window and click the button at the top to enable editing.

Editing labels in script files

At 0x21581 in 1ST_READ.BIN is a string that is prepended to strings in the script files that contain the map location label: "@fs22,22@fm24,0"

When the map label is rendered, the number of characters in the string in the script file is used to calculate the length of the label graphic. It is recommended to edit kanji tiles in SKFONT.CG into the translated text and change the string in the script file to the former kanji. In order to facilitate this change, the above string should be changed to "@fs22,22@fm22,0", setting the @fm value equal to the @fs value.

As noted on the page on SKFONT.CG, an easy way to do this is to start with the first character in the Shift-JIS table and edit enough consecutive tiles to fit the translated label, then using the kanji that used to correspond to those tiles, such as the first four Shift-JIS characters: "亜唖娃阿". This can be repeated as many times as needed with successive characters to translate all such labels. Because the font offset is changed to remove the gap between tiles, some experimentation with text placement within the tiles will be needed to center the label. In most cases, the text should be written slightly right of center. See the below example:

Example translated map label