Inserting fonts into the game

Maks4567

New Member
OP
Newbie
Joined
May 15, 2022
Messages
2
Trophies
0
Age
23
Location
New-York
XP
28
Country
United States
I want to insert a font into the game in order to translate it. I know that font textures need to be inserted through HxD, but how can you tell me? I apologize in advance for my English
 

FAST6191

Techromancer
Editorial Team
Joined
Nov 21, 2005
Messages
36,798
Trophies
3
XP
28,348
Country
United Kingdom
As you did not specify a game we will have to go for the general case.

Fonts can be custom affairs. Why you were told HxD (a hex editor, not even a particularly useful one for ROM hacking purposes) is what you need I don't know.

Anyway so console games tend to use bitmap fonts (as opposed to PCs since... probably the early 90s which use vector fonts). That is to say each character is a little pictorial representation of the thing the devs chose to put there (as opposed to defining the curves and lines with maths and thus being able to scale to any size).
There are multiple schools of thought on how to make them work, and games can and do use any of them. The big two are fixed size (can be bit different to normal graphics tile sizes as well but every character will use the same size tiles in terms of pixel dimensions) and variable size (whatever size they need, with the size defined somewhere else in the font). You can also achieve variable size with fixed size by using a separate table and doing it at runtime (it can make things easier). All Japanese characters are approximately the same width so it tends to take a more forward thinking Japanese dev (or maybe one using a format, usually provided by the console maker, which has it in by default) to implement it in their game, ROM hackers can add it (tends to be called variable width font hack aka VFW hack) but it is one of the harder aspects of text hacking as you will likely need to get your hands dirty with coding. You don't have to do a VFW hack but it can make characters like ijl1yf look odd compared to M W X K and whatever else is full size if not larger, most will add little embellishments to the characters to make them a bit wider, or maybe if something like ll exists in the script (call, hall, fall, tall https://www.thefreedictionary.com/words-containing-ll ) you can combine the two together for those occasions and define a custom character (some even do this for menus where Japanese M I G H T S P A C E O U T things and look odd on English).

Most then find the font however they will (name, extension, elimination, corruption, tracing...) and then open it in a tile editor, or maybe texture viewer if it is a 3d texture (rare for most systems even with 3d, give or take special cases like the PS1, but not unheard of). Figure out what the text encoding is for each character (many methods available here). If they can edit the characters directly there then they will, though recall the earlier part about software defined sizes and custom sizes in general.

Another problem arises should you want to add more characters than the base font encodes. There are three main problems people face here.
1) Not enough characters. Usually seen more for European and middle eastern languages (though they also have the right to left reading issue) that want to add the fun extra characters and punctuation types that don't exist in English and the game maybe only features A-Z,0-9,.,!? for a given font (you might see this in menus or things with more limited need of language) or possibly even less than that (not every menu will have all the characters).
2) Adding characters can be hard as it could speak to the base code of the game. NTFR on the DS notably has software defined encodings within the font so adding things there, especially with nice format aware tools, is actually quite easy but that tends to be the exception in font editing and you might have to get down and dirty with the game's code to figure out how it all works. This mostly means if you can then you instead replace existing characters, if it is Japanese then not so bad as you tend to have lots of choice, if it is an English language game you are using as a base then harder.
3) Graphics memory size within the game. If the game dumps the whole font into memory then you might not have enough memory ( https://www.3dbrew.org/wiki/Memory_layout ) to do something with even if you could store 100000 more of it in the ROM itself.
 

The Real Jdbye

*is birb*
Member
Joined
Mar 17, 2010
Messages
23,327
Trophies
4
Location
Space
XP
13,904
Country
Norway
I want to insert a font into the game in order to translate it. I know that font textures need to be inserted through HxD, but how can you tell me? I apologize in advance for my English
Stuff like TileMolester can be useful on retro consoles. Newer consoles might need more specialized tools.
 

Maks4567

New Member
OP
Newbie
Joined
May 15, 2022
Messages
2
Trophies
0
Age
23
Location
New-York
XP
28
Country
United States
Well, I think I'm will translate kirby planet robotot or kirby triple deluxe to 3ds. And thank you for the information provided
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
    Sonic Angel Knight @ Sonic Angel Knight: :ninja: