Author Topic: "Gears" - The FF7 Documentaion Project  (Read 59726 times)

Topher

  • *
  • Posts: 111
    • View Profile
"Gears" - The FF7 Documentaion Project
« Reply #75 on: 2004-07-10 12:30:58 »
Is there a way to convert the PC data into PSX data so Hack7 will open it?

lasyan3

  • *
  • Posts: 76
    • View Profile
"Gears" - The FF7 Documentaion Project
« Reply #76 on: 2004-07-10 12:36:33 »
It should be really easy, since the only difference between PSX and PC files are the header. I'll see what I can do. But with the current Hack7 you can't use pc files, 'cause it decompresses the files, and PSX files are compressed in a totally different way of the PC files.

Topher

  • *
  • Posts: 111
    • View Profile
"Gears" - The FF7 Documentaion Project
« Reply #77 on: 2004-07-10 12:57:22 »
-- Removed --

Lasyan3 just sent me one.

Thanks!

Terence Fergusson

  • *
  • Posts: 262
    • View Profile
"Gears" - The FF7 Documentaion Project
« Reply #78 on: 2004-07-10 14:54:38 »
Would you mind making the PC reading version of Hack7 available for download?  There's a few scripts I'd particularly like to look at at the moment in order to get some game questions answered.

(Disassembly Update: Finished working on how stats are gained per level.  Now have full data on that, and proven almost without a doubt what the maximum and minimum stats each character can get is)

lasyan3

  • *
  • Posts: 76
    • View Profile
"Gears" - The FF7 Documentaion Project
« Reply #79 on: 2004-07-10 15:27:54 »
If you only need something to read those files, you can use this prog I made for halkun :
http://the-afterm.ath.cx/script_dump.zip

Terence Fergusson

  • *
  • Posts: 262
    • View Profile
"Gears" - The FF7 Documentaion Project
« Reply #80 on: 2004-07-10 16:02:08 »
Thanks.  Very nice program, just a shame it can't read the file I want.

The file I'm interested in is 'frcyo' (yes, I want to get at the chocobo breeding data; I've had enough with this part being such a mystery now.  I know how some things work, but I now want the code so I can decipher it and write up/submit a document based on it).  If you do ever manage to get it to read it, I'd be very interested in an update.

halkun

  • Global moderator
  • *
  • Posts: 2097
  • NicoNico :)
    • View Profile
    • Q-Gears Homepage
"Gears" - The FF7 Documentaion Project
« Reply #81 on: 2004-07-10 16:10:29 »
The chocobo breeding data is in blackbg4. You can look at the pointing Tifa script (tift) and see how the data is accessed.

Terence Fergusson

  • *
  • Posts: 262
    • View Profile
"Gears" - The FF7 Documentaion Project
« Reply #82 on: 2004-07-10 16:25:39 »
That just seems to be how to *access* the data.  It's *changing* the data I'm interested in (though the information was useful since it'll make it easier to track down what's what when I finally have the breeding script).

Topher

  • *
  • Posts: 111
    • View Profile
"Gears" - The FF7 Documentaion Project
« Reply #83 on: 2004-07-10 17:14:40 »
After poking around the source of Hack7 and playing with some PC files I managed to figure out how to tell how many events there are (it seems to be limited to 256/map) and how to list them all...

I'm still trying to figure out how to tell how many scripts there are per event, and how many commands there are per script...

lasyan3

  • *
  • Posts: 76
    • View Profile
"Gears" - The FF7 Documentaion Project
« Reply #84 on: 2004-07-10 17:21:32 »
Quote from: Terence Fergusson
Thanks.  Very nice program, just a shame it can't read the file I want.

The file I'm interested in is 'frcyo' (yes, I want to get at the chocobo breeding data; I've had enough with this part being such a mystery now.  I know how some things work, but I now want the code so I can decipher it and write up/submit a document based on it).  If you do ever manage to get it to read it, I'd be very interested in an update.


I'll do something about this bug.

Terence Fergusson

  • *
  • Posts: 262
    • View Profile
"Gears" - The FF7 Documentaion Project
« Reply #85 on: 2004-07-10 17:48:51 »
Thank you.  I appreciate it.

In the meantime, I guess I'll work on... huhm.  Not sure.  Maybe Critical Strike calculations... still got some unknowns there I'm interested in....

Lord_Skylark

  • *
  • Posts: 115
    • View Profile
"Gears" - The FF7 Documentaion Project
« Reply #86 on: 2004-07-10 19:23:01 »
THe program that I used to decompress the scene.bin file decompresses it so I can read the stats as hex and stuff, but it doesn't decompress the actual battle text/messages correctly. The enemy names and attack names view correctly, but the messages that monsters "say" don't.

Thanks,
~ANdy

Terence Fergusson

  • *
  • Posts: 262
    • View Profile
"Gears" - The FF7 Documentaion Project
« Reply #87 on: 2004-07-10 19:41:49 »
Lord Skylark> It decompresses them fine.  That's exactly how it looks like in memory.  Hell, I was surprised when I saw that the enemy names and attack names were in full ASCII in the Scene.bin dumps; in memory, they're already converted into FF7's alphabet.

Text messages in the AI script are always prefaced by 93 and end with FF.  In general, 10-19 are the numbers 0-9, 21-3A are uppercase letters, and 41-5A are lowercase letters (it's just happy coincidence that the lowercase letters happen to coincide with standard ASCII's uppercase letters).

lasyan3

  • *
  • Posts: 76
    • View Profile
"Gears" - The FF7 Documentaion Project
« Reply #88 on: 2004-07-10 20:35:08 »
I just remembered I had a document about file format for the PSX version. It describes the media files, such as movies, sound and 2D/3D graphics files. link :

Cyberman

  • *
  • Posts: 1572
    • View Profile
"Gears" - The FF7 Documentaion Project
« Reply #89 on: 2004-07-11 00:15:33 »
Halkun: Don't download that file Laysan3 referenced it's something you've repeated asked not to see.

Thanks Lasyan3 although it doesn't have FF7 file formats in it per sea, it does have some of the formats prior to compilation by the tools Square made for there FF games on the Playstation.

I did remember what happened to the documentation I had, heh, I deleted it purposefully.

It was a long time ago.

Cyb

halkun

  • Global moderator
  • *
  • Posts: 2097
  • NicoNico :)
    • View Profile
    • Q-Gears Homepage
"Gears" - The FF7 Documentaion Project
« Reply #90 on: 2004-07-11 01:20:40 »
I can take a guess, I've seen the file offered to me many many many  before when I was making the PSX doc. It was one on my "hit list" of files not to download. Lemme guess, a PDF full of sony's file formats?

Actually, I remeber once I had Psy-Q offered to me a little more focefully than one would think was normal. That was just plain wierd. (I think I told that story)

This is a message that goes out to everyone....


Distrobution of Sony's propriatary documentation is a NO-NO!


Not only is it copyrighted by Sony, it also conatins information that could taint the reversing if the PSX datasets. Posting any Psy-Q related development docs stright from Sony is no different than posting an ISO of FF7.

Actually this is worse as it could invalidate any work done on the PSX data. Do not download this.

(Listens to the PSX reversers go "awww! Man!" as if I just took their candy away.)

I actually have legaly owned Sony's docs once upon a time. I used to have a PS2 Linux kit. Knowing sony, they probably put thier copyright notice on the second or third page like they did with the Linux docs.

Terence Fergusson

  • *
  • Posts: 262
    • View Profile
"Gears" - The FF7 Documentaion Project
« Reply #91 on: 2004-07-11 01:36:29 »
Actually, I've changed my mind.  I'm going to work on the next best thing to Chocobo Breeding: Bone Village.

Was making quite a bit of headway... and then I noticed an undocumented bit in the If...Then code.  The script dumper always lists it as != value... but I don't think that's the case.  Looking at the value translated after the Then, it would seem that that number dictates what the comparison is (just like in Legend of Mana!  Hee!)  (00) is clearly the != expected... but (01) is definitely ==.  Not sure on the other bytes... but would like some feedback if anyone has a full list.  Otherwise, I'm going to have to guess, or something ^_^;

I plan to post the basic information on the GameFAQs MB (and here) once done.  Any conditions/requests for credit, etc, etc?  Otherwise, I'll likely just list you as 'respected people who gave me tools to dump out the script' when I make the GameFAQs post...

Edit: (09) and (0A) are clearly bit comparisons: (09) checks if the bit is not set, (0A) checks if the bit is set.  They're tied to the BIT-ON and BIT-OFF commands.

Cyberman

  • *
  • Posts: 1572
    • View Profile
"Gears" - The FF7 Documentaion Project
« Reply #92 on: 2004-07-11 01:55:43 »
Quote from: halkun
I can take a guess, I've seen the file offered to me many many many  before when I was making the PSX doc. It was one on my "hit list" of files not to download. Lemme guess, a PDF full of sony's file formats?

mmm hmmm :)

Quote from: halkun

Actually, I remeber once I had Psy-Q offered to me a little more focefully than one would think was normal. That was just plain wierd. (I think I told that story)

This is a message that goes out to everyone....

I actually have legaly owned Sony's docs once upon a time. I used to have a PS2 Linux kit. Knowing sony, they probably put thier copyright notice on the second or third page like they did with the Linux docs.

I so wanted that when it came out, then I realized they had made it nigh unto impossible to do anything with it.  Sort of like carefully designing a vegetable so that you can't cook it or doing anything else with it other than wash and eat it raw.  I was so frustrated with that I decided not to waste my money on it. I wonder if there are any kits on EBAY now?  I should get the network device for the PS2 sometime (as I have cable DSL now).

Well it wouldn't surprise me if they seed the information on the net to nail people to protect there property.  I've nothing against Sony in terms of what's theres. The primary thing I have against Sony, is they tend to be hypocritical, about everything they do that is say one thing and do another.  Sony is very good at litigating, they tend to litigate everything.

halkun

  • Global moderator
  • *
  • Posts: 2097
  • NicoNico :)
    • View Profile
    • Q-Gears Homepage
"Gears" - The FF7 Documentaion Project
« Reply #93 on: 2004-07-11 02:22:07 »
Going a little off topic.

I found the PS2 Linux kit very awesome tool when you realize what it's used for. I got rid of mine for reasons other than political.

Yes, you are not going to be able top make games for others to play. Not only that, Sony tells you right off the bat you are not going to make games that will likely be sold to companies. (Most if not all thierd-party developers only deveop in-house for legal reasons)

It was actully the 3rd party deveopers that demanded this, not the public at large. You see, that was happening was the new guys out of college were just having a bear of a time with the PS2. To say it's "difficult to code for" is about as much of an understatement as "outer space is big"

Companies were wasting six months to a year on training on each new deveoper, which was very expensive. They have new emplyees that really coudn't contribute to a project until they were up to speed.

This kit allowed for anyone to tweak under the hood. You gain valube experance so deveopers could hire "right out of the gate" also they didn't have to comb schools. Anyone who consistently produced good code would be considered.

I got mine so I could learn OpenGL and work real close to the metal of a honest to god gaming system legaly. I also wanted to support Sony for making the choice to use linux.

However, I was slammed by the architecture. I knew the PS1 was was very unprepaired for what a PS2 had under the hood. It wasn't a PS1(+1) it was a new Sony system with a ps1 inside it. (Which was locked out, BTW)

That thing has SIX co-prosessers that all had to share a super wide, propritary, 4,096 bit bus in perfect time or the whole graphics subsystem would smash.

What irked me was Sony said it came with OpenGL libaries and it came with MESA that rendered in Software only. Watch gears run in 245 FPS..... ooooh! (It should run 10000+ on accelerated hardware)

It was just too hard. I was plannang on porting epsxe to it (Not as stupid as it sounds) but the way the PS2 was built was so knorked up, I gave up and sold it. I should of at least kept it so I could hack the memory cards, but I had recently quit my programming job, (Yes, I was a paied Linux programmer) and never touched software deveopment again.

halkun

  • Global moderator
  • *
  • Posts: 2097
  • NicoNico :)
    • View Profile
    • Q-Gears Homepage
"Gears" - The FF7 Documentaion Project
« Reply #94 on: 2004-07-11 04:11:09 »
Not exactly a dumble post: I need some information...


Which debug field file is Kitase's? (That's the north one with the shiny Aerith and the half-blue Cloud) I can't seem to find that one.

Terence Fergusson

  • *
  • Posts: 262
    • View Profile
"Gears" - The FF7 Documentaion Project
« Reply #95 on: 2004-07-11 04:13:27 »
Hee.  Been doing a lot of work tonight.

Plot Progression Byte (Word, actually)!  FF7 uses a counter that stores where you are in the basic linear plot.  Here's a few sample values:
03F0: Meteor first appears in the sky
04AD: Cloud and Tifa are found in Mideel rubble (after Cloud recovers)
056F: Bugenhagen takes the Huge Materia from you
0635: Hojo prepares to fire Sister Ray
0644: Right after Hojo's defeat
0654: Disc 3 has begun

No optional stuff are stored in this variable, since it's a purely linear counter.  If you've gotten to a certain number, then you've passed all the points before it.  The address of this variable in the script dumps is referred to as (20)[0000] (it's set via SET-WORD ( 20, 00, <word value>))

Also, I've managed to crawl through most of how Bone Village determines the *exact* prize you get... now I just have to work out how it determines the rough prize category you get.  That's going to be interesting...

halkun

  • Global moderator
  • *
  • Posts: 2097
  • NicoNico :)
    • View Profile
    • Q-Gears Homepage
"Gears" - The FF7 Documentaion Project
« Reply #96 on: 2004-07-11 12:06:39 »
This is interesting. I wonder how many globals dees the engine have? 256 Longs?

Oh BTW, I'm done with the debug rooms. They arn't as complete as I would like them, but they are mapped. I'm going to start on decrypting all the opcodes as soon as my head stops swimming.

(Download updated Gears with my WWW button)

Alhexx

  • *
  • Posts: 1894
    • View Profile
    • http://www.alhexx.com
"Gears" - The FF7 Documentaion Project
« Reply #97 on: 2004-07-11 15:22:59 »
I never though that we (or better YOU) have made such a progress in FF7 hacking... it seems like there are a lot of things already hacked here, which I didn't even know they exist... :o

 - Alhexx

Cyberman

  • *
  • Posts: 1572
    • View Profile
"Gears" - The FF7 Documentaion Project
« Reply #98 on: 2004-07-11 16:05:30 »
Quote from: Alhexx
I never though that we (or better YOU) have made such a progress in FF7 hacking... it seems like there are a lot of things already hacked here, which I didn't even know they exist... :o

 - Alhexx

Deviation from topic
Alhexx there is this black hole out there that represents what one doesn't know.  The problem is the more you learn the closer you get to it, and you realize really how little you do know ;)
End Deviation

I feel like Mandelbrot suddenly

If you think it might be helpful I can work on a tool for scripting in FF7.
The big deal would be syntax (as I would use a syntax highlighter), would you say that FF7' scripting was C like or something weird? (I fear the later is most likely   :roll: ).

Cyb

halkun

  • Global moderator
  • *
  • Posts: 2097
  • NicoNico :)
    • View Profile
    • Q-Gears Homepage
"Gears" - The FF7 Documentaion Project
« Reply #99 on: 2004-07-11 22:54:42 »
The only thing I have is opcodes. A language sentax will have to be created. I would adore to see what the original scripts looked like. I'm still trying to figure out how to express the arguments Do I use hex? Decmial? Should I use C style and start naming variables and then create an #include file. (This is how the infocom compiler "inform" works)

Sierrra used a scripting language for thier adventure games, but you could always look at the sentax in the game itself.

Hmmmm