Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - FeuFeu

Pages: [1]
1
Scripting and Reverse Engineering / FF7 Savemap
« on: 2006-02-14 23:48:53 »
After more than one year of following the forum quietly and anonymously, I wanted to be of some help on understanding the inner mechanics of FF7. I noticed the savemap had holes and decided to start with this, using Gears and the wiki as documentation.

After some bit of coding to be able to modify a psx savegame (I'm using epxse) and perform some quick binary diff between two save files, I was ready to start.

I don't know how accurate the current savemap is, as I've seen halkun say some part of it might be messed up. Anyway, a bit of brainstorming later, I went and tried to find some data I thought would be kept in there. This is what I've discovered so far :


First of all, about 'No Combat' & 'No Movie' flags : even though those options are available in Debug Mode, it appears they are not saved :-(


Offset 0x0C1E (1 byte)
Mask for the "target" text appearing over all available targets in battle
Inactive (0x00) / Active (0x40)

It looks like the other data on this byte are flags about vehicle information. For instance, when you get the Submarine, a text is displayed and lets you know how to control it : then, the mask 0x04 is applied on this byte so that the message isn't displayed again the next time you get on the world map. I haven't been able to test the others, but I suspect there are similar masks for the Buggy, the Tiny Bronco, the Highwind and quite possibly the Chocobo.


Offset 0x0E29 (1 byte)
When you visit the Chocobo Sage, he often has something new to tell you about Chocobo breeding. This byte is the Chocobo Breeding tutorial progression variable.


Offset 0x0E2A (2 bytes)
The total number of battles you must have fought in order to unlock the next part of Chocobo Breeding tutorial.
I don't know if the value added each time is fixed (e.g. a new part of the tutorial available every 5 battles) or random.


Offset 0x0EC2 (1 byte)
Mask for the fields pointers (the hand over party leader's head, red and green arrows on exits, ladders...)
Inactive (0x00) / Active (0x01)


Offset 0x10DA (1 byte)
Masks for general settings
- sound : mono (0x00) / stereo (0x01)
- controller : normal (0x00) / customize (0x04)
- cursor : initial (0x00) / memory (0x10)
- ATB : Active (0x00) / Recommended (0x40) / Wait (0x80)


Offset 0x10DB (1 byte)
Masks for general settings (continued)
- camera angle : auto (0x00) / fix (0x01)
- magic order :
   "1. restore attack indirect" = (0x00)
   "2. restore indirect attack" = (0x04)
   "3. attack indirect restore" = (0x08)
   "4. attack restore indirect" = (0x0C)
   "5. indirect restore attack" = (0x10)
   "6. indirect attack restore" = (0x14)
   (game crashes if flag set to 0x18 or 0x1C)
- extra battle window displaying information about commands & enemies : Inactive (0x00) / Active (0x40)


Offsets 10DC to 10EB (16bytes)
Controller : Button config
Offset 10DC = Left 2 (default L2)
Offset 10DD = Right 2 (default R2)
Offset 10DE = Left 1 (default L1)
Offset 10DF = Right 1 (default R1)
Offset 10E0 = Menu (default Triangle)
Offset 10E1 = Confirm (default Circle)
Offset 10E2 = Cancel (default X)
Offset 10E3 = EXT (default Square)
Offset 10E4 = Help (default Select)
Offset 10E5 = ?? Apparently unused
Offset 10E6 = ?? Apparently unused
Offset 10E7 = Pause (default Start)
Offset 10E8 = Up (default D.Pad Up)
Offset 10E9 = Right (default D.Pad Right)
Offset 10EA = Down (default D.Pad Down)
Offset 10EB = Left (default D.Pad Left)

Pad Buttons (for PSX)
0x00 : L2
0x01 : R2
0x02 : L1
0x03 : R1
0x04 : Triangle
0x05 : Circle
0x06 : X
0x07 : Square
0x08 : Select
0x09 : ?? Apparently unused
0x0A : ?? Apparently unused
0x0B : Start
0x0C : D.Pad Up
0x0D : D.Pad Right
0x0E : D.Pad Down
0x0F : D.Pad Left

Although it is possible to manually change the controls to something unusual (D.Pad Up as Confirm button, for instance), the result is messed up in the config. menu, since not all keys have bitmap associated.


From Offset 0x0FC4 to ??? (?? bytes)
All flags about chests and items to find during the game. For instance :

Offset 0x0FC4
bit 1 (LSB) : Potion #1 on KOed guards (beginning of the game)
bit 2 : Potion #2 on KOed guards
bit 3 : Potion in front of Jesse (in the Mako Reactor)
bit 4 : Phoenix Down in the chest
...


That's it for now :)
There's more data that I think should be there, such as : anything related to the Weapons (visible & defeated flags, Ultimate's HP, location, etc), the number of battles between the two visits at Lucrecia's Cave, the Wutai Quest flag, the timer during the very first mission...


EDIT : changed "Menu (default Square)" to "Menu (default Triangle)". Thanks dziugo for pointing this out.

Pages: [1]