+  RHDN Forum Archive
|-+  Romhacking
| |-+  ROM Hacking Discussion
| | |-+  Ogre Battle hacking
Pages: [1]
Author Topic: Ogre Battle hacking  (Read 2 times)
Aganar
Guest
« on: June 19, 2009, 01:58:27 am »

A few years ago, having become tired of trying to track down the PS1 version of Ogre Battle, I gave up on acquiring it legitimately and played through the entire game on ROM. Flash forward to six months ago, however, and I suddenly see a complete copy of the PS1 version on Ebay for around $40, which I immediately nab.

Normally, I would resolve just to play through the game again on the PS1, load up the ROM whenever I feel like playing through the game again, or download someone else's save of Ogre Battle and use their team. However, I put alot of time into constructing the roster of OB characters that I did, and I want my team, dammit. Hence, while playing through other games on my backlog this summer, it was conceived as a project of mine that I would download someone's endgame save of Ogre Battle PS1, hack the crap out of it until the teams mirrored mine on the SNES version, and then upload that hacked save onto my memory card via the DexDrive.

I hesitate to call this a "hack", really, because I'm not doing anything to the game that isn't being done via simply Pro Action Replay codes. It will be a pain-staking effort, however, as I have to pretty much manually record the stats of over 80 characters, find the appropriate Gameshark codes for the PS1 version of the game, and then change each characteristic of the character (which would include name, number, class, portrait, alignment equipment, and then the stats themselves) until it mirrored his equivalent SNES save character.

The most immediate problem I ran into while trying to do this is that the character's number is not visible to the player, meaning to find it out I would have to go use game genie codes to make the number obvious somehow (like changing the unit cost of Character No. 2 to 200 goth, and so on) and manually note which character is which. It then occurred to me that the game obviously knows which character is which, and so long as I have PAR guides for the SNES and PS1 versions of the game, it should theoretically be possible to write a program that simply goes to that character's address in the ROM and finds all of that information for me. At the very least, I could then have it all outputted to a text file to save me some time. If I got really ambitious, I could even have it automatically translate the character information to SNES PAR codes (i.e. "The PAR codes to generate a character in Slot 2 with the name _____, portrait _____, and stats ____ is...") and then swap those for their corresponding PS1 Gameshark codes.

How feasible is all of this? I don't know exactly how easy or difficult it is to access that sort of information within the ROM (if it even is in the ROM--if it's my character data would it be in the sram?) and use it? I fear I'm drastically simplifying everything in my head, and all of the game's text would be either compressed or inaccessible without a disassembler. But it seems like since I'm not doing anything that couldn't be done with simply an assload of time punching lines into a Game Genie, it shouldn't be too complicated.

My programming skills are also just above shit. I took an Advanced C++ class and a Data Structures class (basically just C++ part two--I don't think we ever got far beyond 2-key tables and data trees), so I can write something that reads stuff in and outputs it to a text file for me, but it doesn't go far beyond that (I was all set to take Java and then embark on a path that would have essentially made me a Computer Science major, but then on a whim I took an Abrahamic Faiths class instead, and coincidentally am now a Religious Studies major, but this is neither here nor there).

Is this at all possible? I feel like if I were to get it working it would make a decent utility for anyone else who might be in my unique situation. At the very least, it could save me some tedious transcribing.
Tauwasser
Guest
« Reply #1 on: June 19, 2009, 03:32:58 am »

Um... so you want to transfer someone else's save and hack that. Why don't you use your original save and transfer that instead of editing another save to be just like your save?

Also, yes, you would have to manually look stuff up in game code and sram to do this work. Also, not all characteristics might be obvious to you in the stats page etc (think pokemon dv and ev). This whole thing is not really feasible unless you use your original data...which I still think you would have if you want to manually copy down all the levels etc.

cYa,

Tauwasser
Aganar
Guest
« Reply #2 on: June 19, 2009, 03:58:31 am »

Quote
Um... so you want to transfer someone else's save and hack that. Why don't you use your original save and transfer that instead of editing another save to be just like your save?

Umm...because I'm transferring across platforms? My original save is on an SNES rom (or rather, a .srm file specifically), which I want to replicate on a copy of the PS1 version of the game. Obviously, I can't transfer save data between an SNES and a PS1 game. The steps I would (roughly) have to do would then be the following:

1. Dump/transcribe data from my SNES ROM save (character statistics)
2. Download someone else's PS1 endgame save (I haven't played through the PS1 version of the game, so I don't have my own save)
3. Edit the PS1 save (either via some tool or by opening it in an emulator and entering pages of Gameshark codes) until the characters match with my lineup in the SNES ROM save.
4. Load the modified PS1 save onto a memory card via the DexDrive so that it can be played on a real PS1 with my physical copy of Ogre Battle.

I can do this all manually, but it seems like a program would be able to at least cut down the tedium. For instance, looking at the PAR guide for the SNES version, I see something like this:

Strength
Character 14
7EF259??

Those two question marks are to be filled in with the hex value of whatever I want the Strength of Character 14 to be. Now, correct me if I'm wrong, but when I enter in a PAR code, the cheat device is simply going to that address (7EF259) and modifying the last two bytes, is it not? In which case, is it possible to have it do the opposite? That is, to write a program that simply goes to that address, records the last two numbers and then converts it from hexadecimal to base-10 and outputs the result for me? That's basically all I would want the program to do for me, in its simplest form: do the dirty work of finding all of the annoying stats for me and recording them somewhere for reference, so that by the end of it I can have a text file that reads:

"Character 14
Name: Lisa
Alignment: L
Level: 30
Class: Siren
Portrait: Siren
etc."

That would make it much easier to then modify the PS1 save.
Tauwasser
Guest
« Reply #3 on: June 19, 2009, 05:36:38 am »

Oh... I didn't get that

Quote from: Aganar
PS1 version of Ogre Battle, I gave up on acquiring it legitimately and played through the entire game on ROM.

meant you acquired the SNES version Tongue

You can only hope for same memory layout or it will be a very difficult task with mind-boggling asm tracking... You could have a program dump the stats to a table... but if you figure out the correct adresses you could probably have it directly copy the stats over. Now, maybe find some codes for PS1 or get into asm. Also, there will probably be values not disclosed by PAR codes or guides... so be aware.

cYa,

Tauwasser
« Last Edit: June 19, 2009, 05:53:05 am by Tauwasser »
Aganar
Guest
« Reply #4 on: June 19, 2009, 08:07:50 pm »

I'm still wondering about the theoretical of how I'm actually going to make a program to access the game's hex, since I don't know offhand how to program a Hex Editor. Presumably if I open an SRM file in notepad I'm not going to see hex, so I have to use something else that can view it. Is there a hex editor that can open the file and then save it somewhere else as hex so that the actual program I write can read/modify it, or do I have to write a program that 'hijacks' the hex editor?

Also, on an OB-specific level (I was hoping some of the people who had done OB hacks in the past might be more familiar with this) is wondering where exactly the game stores the status of 'special character'. With some games, for instance, it would be in the portrait (meaning if I gave a character Destin's portrait, he would act like Destin, cause a game over if he died, etc.), whereas for other games the actual designation/trigger might be somewhere else.
Deathlike2
Guest
« Reply #5 on: June 19, 2009, 10:11:36 pm »

Hex editors open and save the data in the same originating format... which is still ultimately binary.
Ryusui
Guest
« Reply #6 on: June 19, 2009, 10:54:17 pm »

Hex is just a different way of expressing the same old numbers you're used to. You won't break anything if you think in terms of "16, 32, 64, 255" instead of "10, 20, 40, FF", just as long as you keep your bases straight. (Though it's undeniably helpful if you can learn to think in hex.)

There's nothing magical about a hex editor. Notepad takes the numbers that make up a file, translates them into ASCII and displays them to the screen. A hex editor is the same kind of animal, but instead of converting the data to ASCII, it presents the data to you as the computer sees it: raw, unprocessed bytes, eight-bit digits in base 16. (You might have caught on to this already, but hex is very convenient when working with bytes. The highest value any single byte can represent is 255, or FF, which is also the highest value any two-digit hex number can represent. Starting to get the picture here?) You won't need to perform any conversions or chant any spells or learn any high-level electronic voodoo to create a program that can dissect a ROM down to the minutest detail, just as good as any hex editor (but of course specialized for your purposes). Files are made of bytes, bytes are numbers, numbers can be expressed just as well in base 16 as they can in base 10 (or base 8, but octal is way outside the scope of this discussion, as are any of the other myriad base-N systems you can imagine).

That's really all there is to it.
Pages: [1]  


Powered by SMF 1.1.4 | SMF © 2006-2007, Simple Machines LLC