Adding accents on letters (Game Boy games, Link’s Awakening Specifically)

Started by bípbúp, May 19, 2023, 04:57:38 AM

Previous topic - Next topic


I decided to try to make a translation of Link's Awakening into another language as a first project as it's a relatively small game, and I thought Links Awakening Level Editor (LALE)  would make it an easier project.

The issue is that when I try to use accents on the letters (Á á, É é, Í í, Ó ó and Ú ú are the only ones I will be using), there get changed to random characters.

I tried loading the French Rom into LALE to take advantage of the French accent set (not exactly identical but my intention would be obvious to any reader) but LALE would not recognise the French rom as a legitimate copy of the game.

I've read on the description for the improved French translation rom hack that there is little support for capitalised letters featuring accents, so I will try to avoid those if my translation moves forward, but otherwise, is there anyway I can add or make use of accents in the version of the game that LALE accepts?

 :beer:  :beer:


Games for most things prior to maybe the 360 do not use the same encodings as normal PC programs would use. This means most hackers have to figure out the custom encoding used for that given game. Sounds like you have an editor that can shortcut it though. Equally as space is often tight then only what is needed for the game (give or take Japanese) gets loaded in.

You then either get to expand the encoding to include extra data, which is a considerable feat in most older systems (if you are playing with tools to edit things then way way way beyond that) or find some characters you don't mind losing in the existing font file to overwrite (possibly also alter size of in some systems, though less likely to see that on the GB/GBC).

Alternatively if LALE is open source you might alter it to support the different region ROM, or use the existing one to learn how the game works as chances are it works much the same in the other language but with different locations.

Someone has possibly come before you though
Details where some of the alphabet as they term it might be found.
See what goes with a tile editor set to GB modes if you view there.
If it is there (or otherwise found by scanning around or more involved means) then time to edit, I doubt it will be compressed.


Hi fast6191
Got a tile editor and did as you said - swapping letters I don't need for ones I do need. Thanks for the advice! It's cool seeing all the graphics lined up and being able to change the text around and so on
Thanks so much!


Hi, I made the mod with improved French accents!

If you're looking for accents on lowercase letters, editing the font tilesheet of the English ROM will be good enough, and seems to produce a rom editable by LALE.

However, if you want accents on uppercase letters, then we speak about special diacritic tiles that get inserted above selected characters. You can even see those two diacritics (acute and grave) in the font tilesheet. The code for diacritics is disabled in the English version, but enabled for the Japanese and German ROM. So you can see if LALE supports for instance the German ROM, which supports diacritics.

And otherwise, you can try to recompile the English ROM with diacritics support. This is done by enabling the __DIACRITICS_SUPPORT__ flag at compile-time in the disassembly. However, this will shift the instructions in bank0 and bank1 by a few bytes, which may confuse LALE. Worth trying though! If this works, the source code of the French-with-accents mod may be of some help.

(And with a little more assembly hacking, you could even devise a way to enable diacritics support without shifting the code (e.g. by moving the routines to an unused bank, and jumping to it).)


Hi, thanks for the advice!

I've actually started translating the text with both lowercase and uppercase letters replaced altogether by accented letters. It's not so much of an issue for me because Irish has far less letters than English. Outright replacing letters probably isn't a good programmers solution but it works well enough for me  :thumbsup:

I'm making good progress with the translation and I'm very excited to share it. The accents are working perfect so I'm delighted with myself, and I've been able to shift around game graphics to be in Irish as well (I was confused for ages about why when I changed signs and so on in the tile editor why they would still be in English when playing the game, turns out there's a copy for nearly all graphics in the game and I had to change the graphics from the second set rather than the first. I assume the first copy of the graphics would be used for when the game was being played on an original game boy. Interesting though).

There's only one other Irish translation on this site (original Zelda!) so it'll be cool to have something more text-heavy I think. There seems to be a lot of interest for an Irish translation of Zelda as well because I've seen since there's been cancelled translations for both a link to the past and majoras mask. Shame they've been cancelled :(

Thanks again for your message, it was very helpful and interesting as well. I just think it's very interesting how they put this game together.


Hi, I took a look at this game a while ago.

This game approaches its font in a surprisingly modern way. Modern games usually include the font as a raw image, followed by metadata with extra details like a list of characters, their metrics, and so on.
Of course TLoZ:LA doesn't have font metrics to speak of (it's a fixed width font after all), but it does use the ASCII character encoding for the text, which does NOT match the order used in the image. The game has a table (which you have to edit with a hexadecimal editor) that details how the encoding is mapped to the font: each entry in that table represents a possible value from 0x00 to 0xFF (unsure about upper limit) meant for the value in the text data, and that entry's value is the tile ID from the image matching that character. That's how you can extend your font to include diacritics, short of using the Japanese version.

Every Zelda game onwards (including OoT and more modern platforms) seem to follow the same principle, with additional information for glyph metrics (the xadvance, xoffset, and draw width values). The main reason is so that they can use standardized Japanese encodings without being bound by a specific glyph order in the font image, so that image can be incomplete and include only as much characters as needed.