Points of Required Attention™
Smaghetti, a new Super Mario Advance 4 editor, is currently in development! Check out the thread HERE!

Please chime in on a proposed restructuring of the ROM hacking sections.
Views: 88,319,671
Main | FAQ | Uploader | IRC chat | Radio | Memberlist | Active users | Latest posts | Calendar | Stats | Online users | Search 03-29-24 01:31 PM
Guest: Register | Login

0 users currently in ROM Hacking | 1 guest

Main - ROM Hacking - Finding the pointers pointing to the actual text? New thread | New reply


LvKeulen
Posted on 12-03-08 05:25 PM (rev. 2 of 12-03-08 05:28 PM) Link | Quote | ID: 95497

Newcomer
Level: 6

Posts: 1/4
EXP: 598
Next: 309

Since: 12-03-08
From: The Netherlands

Last post: 5594 days
Last view: 5126 days
Yes, I'm new at this ROM hacking/translating thing. Yes, I did try Google. Yes, I probably entered the wrong terms while searching and my topic title is probably incorrect.

The question I want to ask is - for Ocarina of Time, for example - how do you find the offsets for the pointers, pointing to the actual text? Sure, it's nice editing the text at it's original positions, but that's pretty limited and likely very buggy, especially for sentences that become longer as you translate them.

Any answers, or further help, are appreciated.

[edit] I dunno if it's useful, but the offset for where the intro story starts ("In the vast, deep forest of Hyrule...") would be 008A27A4. I use Windhex and HxD. [/edit]

____________________
Above retarded post is brought to you by myself.

blackhole89
Posted on 12-03-08 06:25 PM Link | Quote | ID: 95499


The Guardian
Moloch whose eyes are a thousand blind windows!
Level: 124

Posts: 2114/4196
EXP: 21485115
Next: 351486

Since: 02-19-07
From: Ithaca, NY, US

Last post: 443 days
Last view: 56 days



The universal method regardless of the console used would be, I suppose,
(1) finding out how your particular ROM is mapped (i.e. how offsets in the ROM file correspond to offsets the emulated CPU "sees" - depending on the console, this could be trivial, a bit of trial-and-error or considerably hard to do without trying to tap on how the emulator loads it)
(2) calculating the "real" offset of the text you found (i.e. in a headered SNES LoROM image, $83A2 in the ROM image would correspond to $01:81A2)
(3) from the word order etc. of the machine you are working on, determine a viable byte representation of the address you obtained (this might not work unconditionally if addresses aren't stored in one piece or you have a "complex" system like on the SNES - try looking for lower bytes of the address only in that case)
(4) search the ROM for said representation
(5) for any match, see if the data around it looks like pointers too; if it does, calculate back to ROM image addresses and see if they point at text too - if they do, you found your pointer table.

____________________



LvKeulen
Posted on 12-03-08 06:47 PM Link | Quote | ID: 95500

Newcomer
Level: 6

Posts: 2/4
EXP: 598
Next: 309

Since: 12-03-08
From: The Netherlands

Last post: 5594 days
Last view: 5126 days
Is there any more detail to find on that? I never really 'hacked' a rom before, I only edited some text through a hex editor until a point where it didn't fit anymore.

____________________
Above retarded post is brought to you by myself.

blackhole89
Posted on 12-03-08 06:52 PM Link | Quote | ID: 95501


The Guardian
Moloch whose eyes are a thousand blind windows!
Level: 124

Posts: 2115/4196
EXP: 21485115
Next: 351486

Since: 02-19-07
From: Ithaca, NY, US

Last post: 443 days
Last view: 56 days



For N64 mappings, you best consult somebody who's actually worked on hacking with that console; apart from that, there are no parts in my explanation that have anything to do with hacking know-how (apart from, perhaps, "having the eye" for pointers in the immediate area of some offset); it's all plain arithmetics.

____________________



LvKeulen
Posted on 12-03-08 10:19 PM Link | Quote | ID: 95529

Newcomer
Level: 6

Posts: 3/4
EXP: 598
Next: 309

Since: 12-03-08
From: The Netherlands

Last post: 5594 days
Last view: 5126 days
I'm not sure which hacker for the N64 I could contact to help a newbie out. Some of them mind, some of them do not.

____________________
Above retarded post is brought to you by myself.

Trax
Posted on 12-04-08 01:17 AM Link | Quote | ID: 95549


Yellow Stalfos
Level: 71

Posts: 659/1145
EXP: 3028903
Next: 138211

Since: 07-06-07
From: Québec

Last post: 3599 days
Last view: 2851 days
Maybe you should try with NES or SNES first, and when you get accustomed to it, try N64...

NES pointers are always 2 bytes, and in little endian format...
I'm not sure about SNES formats, but there are plenty of people and docs that can help you...

LvKeulen
Posted on 12-04-08 07:17 AM (rev. 2 of 12-04-08 08:59 PM) Link | Quote | ID: 95643

Newcomer
Level: 6

Posts: 4/4
EXP: 598
Next: 309

Since: 12-03-08
From: The Netherlands

Last post: 5594 days
Last view: 5126 days
I actually started here, but since there's a patch and table files to download, it just seems like everything has been done already.

Doing NES games seems like a good idea. I'll try that. Thanks.

[quickedit]
Are NES games limited to the text size they were given? Can you not put text in some empty space and change the pointers a bit to make it work, like in the GBA?

____________________
Above retarded post is brought to you by myself.

messiaen
Posted on 12-06-08 09:11 PM Link | Quote | ID: 95990


Cheep-cheep
Level: 32

Posts: 95/193
EXP: 203961
Next: 2481

Since: 05-26-08
From: Porto Alegre, Brazil

Last post: 4415 days
Last view: 4743 days
Try looking this topic at Zelda Coalition.

Trax
Posted on 12-06-08 09:28 PM Link | Quote | ID: 95999


Yellow Stalfos
Level: 71

Posts: 670/1145
EXP: 3028903
Next: 138211

Since: 07-06-07
From: Québec

Last post: 3599 days
Last view: 2851 days
Posted by LvKeulen
Are NES games limited to the text size they were given? Can you not put text in some empty space and change the pointers a bit to make it work, like in the GBA?

Yeah, assuming you stay in the same bank or you know what banks are loaded at the time the text strings are used. I guess the NES is somewhat less forgiving than GBA on that matter...

And you have to check how the text string's length is determined. Usually, you have a terminator byte, like FF. And you have to check how the text is displayed on the screen, or you will see strange results, like text wrapping and wrong palettes, stuff like that...

In any case, the key is to understand the game's mechanics as much as possible...


Main - ROM Hacking - Finding the pointers pointing to the actual text? New thread | New reply

Acmlmboard 2.1+4δ (2023-01-15)
© 2005-2023 Acmlm, blackhole89, Xkeeper et al.

Page rendered in 0.061 seconds. (340KB of memory used)
MySQL - queries: 67, rows: 95/96, time: 0.041 seconds.