-
Notifications
You must be signed in to change notification settings - Fork 37
Tutorial: Translating Misc Text
text_misc.yml
is difficult to translate because the text in this file will all be inserted back into the same place it was originally pulled from. This is problematic because it means you cannot make the text any longer than it originally was. So, if a string was originally seven characters in English, it will only be able to be seven characters in your target language.
So, how do we fix this? To understand, we'll first go over the concept of pointers and memory addresses. If you already understand this, feel free to skip over the next section.
The EarthBound ROM is made up of bits of information, binary values represented by 1s and 0s. To keep things nice and simple, these 1s and 0s are represented by hexadecimal values. Sounds complicated, I know, but believe me. It really does make things much simpler. So! Hexadecimal is pretty simple! It's a method of counting that has 16 values. Where the normal way we count has 10 values (0 1 2 3 4 5 6 7 8 9)
, hexadecimal has another 6 values for a total of 16 (0 1 2 3 4 5 6 7 8 9 A B C D E F)
.
So, why is this important? Remember when we setup a font, and we represented each character in the new characters we added with a value like B0
? B0
is a hexadecimal value, and when the game sees it in the right context, it knows to print out a character from your expanded font! Very cool. While hexadecimal is used for things like the font, it is also used to indicate locations in the EarthBound ROM. Each byte in the ROM is represented by an address. For reference, a byte is made of two hexadecimal digits, such as C0
, which means each letter in the game text takes up a byte!
When CoilSnake writes all the text you translated into the game, it converts each character into a byte and puts it into the EarthBound ROM. Most of this text is added to a portion of the ROM known as Expanded Memory (because we made the EarthBound ROM a little bigger so we could add more stuff to it), but this isn't the case with most of the misc text strings (remember, they get written back to the original spot they were pulled from). The best solution to this problem, without changing CoilSnake itself, consists in separately inserting the text in Expanded Memory via CCS files, but since we just added this text without letting the game know about it, it will still load the old spots with the old text.
Luckily, in EarthBound's ROM there are thousands of memory locations that contain what is called a pointer. A pointer tells the game where to find a specific value or data. There are pointers that tell the game where to find sprites, pointers that tell the game where to find strings of text, and much more. By changing these pointers so they point to new locations in our Expanded Memory, we can let the game know where all the new stuff we've made is. In addition to this, and so that the game properly displays our longer text, sometimes we will also need to change some arguments and multiplier functions (as in spots in ROM that, for example, say "print 10 characters").
Changing a pointer is particularly valuable when we have something that is bigger than it was in the original EarthBound ROM, and luckily CCScript makes the process pretty easy!
In the following link, you can find a CCScript file that aims to expand the max length of every string in text_misc.yml
, also allowing you to change some (X,Y)
offsets for the text to be nicely rearranged in windows. In order to use it, you will need to download this file (expanded_misc_text.ccs
) and place it inside the ccscript
folder in your project, doing the same with asm65816.ccs (if you don't have it already), which is required for the first script to work.
This file is pretty global as it includes every misc text string, which means that it most likely is incompatible with other CCS files that share the same goal. Finally, keep in mind that using it will overwrite any possible changes you would have made in text_misc.yml
.
- Overworld Sprites
- Battle Backgrounds
- Battle Sprites
- Title Screen
- Window Graphics
- Logos
- Fonts
- Animations
- Swirls
- EB Project Editor
- Tile Data
- Tile Editor
- Collision Data
- Adding Map Palettes
- Map Editor
- Doors
- Warp Styles
- Enemy Placement
- Hotspots