[Need Hexadecimal Help!] Final Fantasy V Non-Main Character Name Change

Started by linkncb16, January 01, 2016, 05:13:01 PM

Previous topic - Next topic

Spindaboy

I am trying to find a way to edit the names of Lenna, Krile, and Faris for either the SNES or GBA version of FFV, but don't know where to look. Does anyone know if it is possible via hex editing or other means?

KingMike

"My watch says 30 chickens" Google, 2018

Spindaboy

Relative searching documents? Would you mind explaining?

SunGodPortal

Look around for a table file for the version of FF5 that you want to edit (or make one yourself). Then load the ROM and the table file in a hex editor that supports table files. Search for the text you want to change. Change it.

That will probably be the way to do it since I doubt there is a script editor for this game lying around anywhere.
Cigarettes, ice-cream, figurines of the Virgin Mary...

Spindaboy

I found a ROM Map that claims the character names are located from D1/5500-D1/551D. This is confusing because the last hex offset in the ROM from what I can tell is 001FFFF0. The version I'm trying to accomplish this on is the original SFC ROM with no patches. Here is a link to the ROM Map I'm using: http://slickproductions.org/slickwiki/index.php/FF5_ROM_map

SunGodPortal

Hmm. Maybe someone more familiar with it will chime in. It's strange that the ROM map starts at C0/0000.
Cigarettes, ice-cream, figurines of the Virgin Mary...

Spindaboy

Offset D1/5500 would be the same as D15500, right?

SunGodPortal

That's what I would assume, but if it doesn't match up to the ROM then something's wrong.
Cigarettes, ice-cream, figurines of the Virgin Mary...

KingMike

Quote from: linkncb16 on January 02, 2016, 06:28:13 PM
Offset D1/5500 would be the same as D15500, right?

You need to covert that from a CPU address to a ROM address. If FF5 is a HiROM game, subtract $C00000 to get ROM address $115500. (it probably is, judging by the addresses, but it will say HI or LO when starting the game in SNES9x.
"My watch says 30 chickens" Google, 2018

SunGodPortal

Ohhhh. Okay. Man I hate when stuff is listed in SNES addresses instead of PC...
Cigarettes, ice-cream, figurines of the Virgin Mary...

Spindaboy

When I loaded the ROM it said "Bank: Hi," so I assume that means it's a HiROM game. Can you explain in a bit more depth how I would find the D15500 offset I am looking for?

SunGodPortal

#11
QuoteCan you explain in a bit more depth how I would find the D15500 offset I am looking for?

If you don't want to do it manually (and why would you?) you can download and use this program:

Lunar Address

Set your ROM type (and pay attention to the "header" check box on the right, otherwise your address may be 200 bytes off), input your address and it will convert it for you. You can then open a hex editor and "go to" the resulting address (which I believe is 115700). There you may find the data you are looking for.

You'll need a table file to make any sense of what you find there except for the off chance that it's in a format that will automatically be interpreted as text. Slick may have one but I know that Data Crystal has table files for both the original Japanese and at least one of the english translations.
Cigarettes, ice-cream, figurines of the Virgin Mary...

Spindaboy

I used Lunar Address and I also got $11:5700 which was indeed in the table! I just have a few more questions (forgive me, I have been learning so much in the past week!)
1. What is the importance of the $200 Copier Header and when do I include it
2. What is a "table file" and how do I find it
3. What was the original format and why was it in that format anyway (D1/5500)

Also, when I went to the offset $115700 and all I could see were the values 18 18 18 18 etc. which I have no idea how to translate into text and vice versa.

KingMike

Quote from: linkncb16 on January 03, 2016, 12:53:39 AM
I used Lunar Address and I also got $11:5700 which was indeed in the table! I just have a few more questions (forgive me, I have been learning so much in the past week!)
1. What is the importance of the $200 Copier Header and when do I include it
2. What is a "table file" and how do I find it
3. What was the original format and why was it in that format anyway (D1/5500)

Also, when I went to the offset $115700 and all I could see were the values 18 18 18 18 etc. which I have no idea how to translate into text and vice versa.
1. Copier headers were data added by very old (floppy-disk based) copier devices when they were first used to copy the data from actual carts to ROM files. Nowadays they are completely useless and I would advice using a tool to delete them.
To find out if your ROM even has a header, the easiest way in Windows is to look at the file size. If it's an even number (like 2,048KB or 2,560KB) then it doesn't have a header. If it's an odd size (like 2,561KB) then it has a header.
2. A table file says which text character (or characters) each hex value represents. (like in standard ASCII, which hex editors will display by default 41=A). Many games, including most on older consoles, do not use standardized codes. You may be able to find a table by searching google for other sites but RHDN does not host game-specific table files as it is considered an important beginner's learning experience for users to make their own.
3. D1/5500 (or D1:5500 or D15500 or other possible notations) are representative to how the SNES CPU would read the ROM address (which is different than how a human would understand it, it would require going into technical explanation of the hardware to say why). Though it most important to ASM (the system's programming code) hackers to know how to convert ROM addresses between CPU form and the actual file address, it may be an important step later if you want to move text to a different place in the ROM.
"My watch says 30 chickens" Google, 2018

SunGodPortal

Quote1. What is the importance of the $200 Copier Header and when do I include it

The only time it had any importance whatsoever was in the early days of creating and playing ROM images. These days emulators ignore them and the only reason why we ever need them is if someone creates a ROM hack/hacking utility that was built around a headered ROM (likely due to chance as it was simply the "version" they ended up downloading). I guess "copier" headers would tell the copying device what chips were in the cart that the ROM came from so it would know how to interpret the game data.

Quote2. What is a "table file" and how do I find it

A table file is a list of all of the letters and symbols used in a particular game's dialogue and what hex values correspond to them when viewed in a hex editor. They typically also contain stuff like control codes like line breaks, when to wait for the players response, when to scroll and sound-effects that may be triggered during certain dialogue. EDIT: I guess the extent of that stuff depends on the game. Akazukin ChaCha allows you to set the size of text boxes/bubbles with one byte in the dialogue, whereas I believe other games are not so cool.

There are multiple tables for FFV here. If there isn't one available for download you can copy and paste the table you want into a plain text file and change the file extension to ".tbl".

Quote3. What was the original format and why was it in that format anyway (D1/5500)

Well, if you asked the SNES it would say "D1/5500", but for anyone using a hex editor who isn't making ASM mods or rewriting pointers it will be in PC form: $115700, $11:5700, 115700, etc... As far as I know you only really have to use a SNES address form when you are coding. Otherwise I can't think of a situation where you wouldn't just be using PC addresses.
Cigarettes, ice-cream, figurines of the Virgin Mary...

Reiska

Worth noting: Changing the names there will only change them in the menus, battle UI, etc.  It won't change them in the script (since FF5 normally does not have character rename functionality, the character names other than Bartz's are hardcoded into the script).  Changing the names in the script is a significantly more difficult undertaking (one beyond me).

Spindaboy

#16
I figured so. By "hardcoded" you mean the actual names of the other characters are coded into the text as opposed to Bartz's which is subject to change based upon what the player names him?

January 03, 2016, 11:04:16 AM - (Auto Merged - Double Posts are not allowed before 7 days.)

Okay. So I finally figured out that the version of the ROM I'm using does not include the $200 Copier Header and that was why I was being directed to the incorrect offset. I verified that I was in the correct section by checking the values of the hiragana/ katakana which all matched up perfectly with the names of the characters. Strangely though, the changes I made were not reflected in-game anywhere (dialogue, menu, battles, etc.). I started a new game to see if that would rectify the issue, but still nothing. I am confident I have done everything correctly so I don't know what the problem is.

KingMike

Are you sure your ROM is not set to Read-Only (right-click on the ROM and click Properties) and you're not reading from a read-only device like a CD?
"My watch says 30 chickens" Google, 2018

Spindaboy

The read only option in the properties is not activated.

SunGodPortal

When making changes to the text in a ROM it's a good idea to start a game from scratch with a new save file. Savestates in particular are really bad about not reacting well to text changes (at least in A Link to the Past).

If the character names are not always stored as values (I doubt they would be) you'll need to go through the entire script and change every occurance of the names you want to change. You could be looking at hundreds of changes.

Choose a name you want to change, pinpoint the first time it comes up in game(play), write down the text that it is included in, search for that in a hex editor with your ROM and table file loaded, make the changes, save and then load the game.
Cigarettes, ice-cream, figurines of the Virgin Mary...