Author
|
Topic: How does one discover the fonts stored in a game? (Read 849 times)
|
Dais
Guest
|
|
« on: November 20, 2007, 08:06:22 pm » |
|
Just as a matter of curiosity (since I'm not a hacker or translator), I was wondering...exactly what is the process of discovering what fonts a game has - to see if it has an English font, and if that font is VWF, and so on? Is it a complicated process that requires the extensive technical knowledge of programming languages/hex editing and such that romhackers need, or could any shmuck (me! me!) do it with a half-hour and the right tools?
(I imagine it's stored differently in many games, but I also imagine there are certain standards and tell-tale signs...)
|
|
|
|
Ryusui
Guest
|
|
« Reply #1 on: November 20, 2007, 09:38:11 pm » |
|
If you're lucky, you could do it in under 60 seconds.
Just crack the ROM open in Tile Molester/Tile Layer Pro/your favorite tile editing app and scroll through the gibberish until you strike oil. I mean, font. In many if not most cases, this should dig up the game's font with only a minute or two of searching. Note that some games do have more than one font, however. SF1 drove me nuts for a while because I had found one font but missed the other: one was in the order of the game's table, while the other (the one that was actually printed, ironically) was not. On the upswing, it supported ASCII characters by default.
There are a few caveats to note when searching SNES ROMs, though. For starters, they have a propensity for storing their fonts in Game Boy 2BPP format; for seconds, a lot of kanji-heavy games cheat by using odd font dimensions, like 12x16 or the like, which can only be viewed using a special util: you could, for instance, rip them with FEIDIAN if you're certain you know the format.
And if searching a ROM fails to turn up a font, odds are it's compressed, which is a whole different kettle of fish (though not by any means an insurmountable obstacle).
I've never encountered a game with a built-in VWF myself, so I can't give any tips except for common sense: if it looks like it could be a proportional font (i.e. i's, l's and the like are left-aligned rather than centered), try changing some game text to use those characters and see if the text is auto-formatted.
|
|
|
|
Dais
Guest
|
|
« Reply #2 on: November 21, 2007, 04:23:03 pm » |
|
Ah, right, tiles! I shouldn't realized that. Thank you very much!
Hmmm...romhacking really is a "either you know how to do it or you don't" kind of thing, isn't it?
|
|
|
|
Ryusui
Guest
|
|
« Reply #3 on: November 21, 2007, 06:01:09 pm » |
|
The chief obstacle for newcomers is just how interlinked seemingly disparate aspects of romhacking are. I recommend you start by learning how hexadecimal works.
|
|
|
|
Fras
Guest
|
|
« Reply #4 on: December 29, 2007, 09:32:01 pm » |
|
I guess i got a little too advanced stuff for my level(never romhacked before... >_>) In an attempt to train I tried to translate a SNES game called 'Battle Jockey'... I failed with all methods i tried... After a little googling, it seemed like someone else had tried to translate it, but put it on hold because it was compressed... And it sure became a whole different kettle of fish. Don't know how to proceed... Saw a document in the 'Documents' section about solving some compression cases with assembly and C, but that seems to be out of my level. Maybe I should just give up on that. >_>
|
|
|
|
Ryusui
Guest
|
|
« Reply #5 on: December 29, 2007, 10:46:46 pm » |
|
Well, I suppose I should relate my recent experience here.
DS hacking is a bit more like disc-based hacking: instead of a massive agglutination of data, the ROM is actually comprised of individual files all glued together. There are numerous apps that can be used for cracking a DS ROM open into its constituent files - NDS Top System is my current weapon of choice - and finding graphics is usually as easy as browsing directories and looking for the telltale file extensions.
I found the font for "Death Note: The Kira Game" easily enough: it's "font.nftr", located in the "font" subfolder. This, of course, is where things got ugly. I opened the file in Tile Molester and was immediately stymied: none of the codecs or display modes would produce a legible font. This I took to mean that the font was compressed, and that I needed to do some trace work to extract it. I dug up the print routine, ran through it a few times, and was confounded by two discoveries: first, that the game was performing no decompression that I could discern, and second, that the font tiles which I thought were compressed were actually arranged neatly in 16-byte blocks: if the data was compressed, all the font data would be mixed together in one big chunk.
It took a leap of intuition for me to recognize why I couldn't view the font in Tile Molester despite the apparent lack of compression. The font tiles are 11 pixels by 11 pixels, stored in a decidedly non-standard space-saving format: rather than lining up 8 pixels at a time, each 11-pixel line is stored between bytes.
For example:
10000000000 10000000000 10000000000 10000000000 10000000000 10000000000 10000000000 10000000000 10000000000 11111000000 00000000000
Is actually stored like this:
10000000 00010000 00000010 00000000 01000000 00001000 00000001 00000000 00100000 00000100 00000000 10000000 00011111 00000000 00000000 00000000
I was able to extract the font for viewing using FEIDIAN...interestingly enough, in addition to English and Japanese fonts, there's even Greek and Cyrillic in there.
|
|
|
|
satsu
Guest
|
|
« Reply #6 on: December 30, 2007, 05:15:11 am » |
|
I was able to extract the font for viewing using FEIDIAN...interestingly enough, in addition to English and Japanese fonts, there's even Greek and Cyrillic in there.
I think they tend to appear in games that use Shift-JIS rather than the usual thrown-together encoding/characer sets -- I remember seeing them in few other games like GetBackers on the GBA. Greek and Russian translators take note.
|
|
|
|
Fras
Guest
|
|
« Reply #7 on: December 30, 2007, 03:08:58 pm » |
|
Well, what do you know! I keeped looking and completing my character table for Battle jockey.... After a while, i discovered the katakana and hiragana characters! There is already a set of romaji in there, thanks to the really bad english intro too, and everything seems to be easy to edit
|
|
|
|
|