Author Topic: CHRONO CROSS FILE EXPLORATION THREAD  (Read 64730 times)

cornettheory

  • Architect of Kajar
  • Earthbound (+15)
  • *
  • Posts: 21
  • Hey! lets Fight for no reason! Okay Bye!
    • View Profile
    • www.onlyintheory.com
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #630 on: June 21, 2008, 02:26:27 am »
fantastic.  the dynamo of reverse engineering continues toward the horizon.

MDenham

  • CC:DBT Dream Team
  • Chronopolitan (+300)
  • *
  • Posts: 330
  • Glowsticks are not a weapon.
    • View Profile
    • Java IRC - konata.echoes-online.com
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #631 on: June 21, 2008, 03:11:16 am »
I'm a bit miffed that a texture page indicator would be stuffed into vertex pointers, but it's an accurate indicator of which texture the game engine is looking at when it pulls UV pieces based on manual UV mapping exercises. Halkun, Cyb, and M, does this seem plausible?
Makes enough sense to me, and I can understand why they did it that way (might as well use those unused bits for something, after all...).

The question then comes up, though, of "is there anything with more than two textures?" (referring specifically to battle models), as this system should support up to eight textures per model...

Satoh

  • CC:DBT Dream Team
  • Magical Dreamer (+1250)
  • *
  • Posts: 1291
  • Am I your dream... or are you mine...?
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #632 on: June 21, 2008, 04:04:56 am »
A note about weapon textures, I never gave a number, as I never found evidence to the dimensione in the hex(I'm still learning structure) But textures as viewed through PSicture are 128x85 which is decidedly not your typical power of 2 texture... and they are 4bit. Also, to be clear, it is one texture per weapon.

All of this has more than likely been previously noted by some.

MDenham

  • CC:DBT Dream Team
  • Chronopolitan (+300)
  • *
  • Posts: 330
  • Glowsticks are not a weapon.
    • View Profile
    • Java IRC - konata.echoes-online.com
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #633 on: June 21, 2008, 04:18:50 am »
A note about weapon textures, I never gave a number, as I never found evidence to the dimensione in the hex(I'm still learning structure) But textures as viewed through PSicture are 128x85 which is decidedly not your typical power of 2 texture... and they are 4bit. Also, to be clear, it is one texture per weapon.

All of this has more than likely been previously noted by some.
Yeah, the original figure I was getting was 32x85 - which, unfortunately, is the result of something not being worded right in the description of how things work.  (There's eight bytes that run, for example, 80 01 00 01 20 00 55 00 - in Serge's weapon pack, the first time is at 0x00080 - which makes it look like it's 32x85.  Unfortunately, the "32" is the number of words per line, not the number of pixels...)

Since the texture data is enough to be 128x85, this would have made it seem like there were four textures per weapon.

(BTW, 85 isn't that odd of a dimension - it's 1/3 of 255 - but agreed on the "not your typical power of 2" obviously.)

FaustWolf

  • Guru of Time Emeritus
  • Arbiter (+8000)
  • *
  • Posts: 8972
  • Fan Power Advocate
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #634 on: June 21, 2008, 10:23:08 am »
Aaack, that's what I get for trying to report things by memory. Yeah, the weapon textures are 128x85 pixels. It wouldn't be too much work to go through an add the necessary black space to make them 128x128 pixels though. I've been doing that with the 128x128s to "force" them into the 128x256s that the Blender script currently expects, and it works. So if powers of two saves you some major work Luminaire, I can accomodate manually as I gather textures. With the exception of the swallows and the weird weapons, lots are repeated among characters as it is, with just the weapon trails different.

Luminaire85

  • Guru of Time Emeritus
  • Chronopolitan (+300)
  • *
  • Posts: 311
    • View Profile
    • Chrono Cinema
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #635 on: June 29, 2008, 10:30:37 am »
I'm a bit miffed that a texture page indicator would be stuffed into vertex pointers, but it's an accurate indicator of which texture the game engine is looking at when it pulls UV pieces based on manual UV mapping exercises. Halkun, Cyb, and M, does this seem plausible? Luminaire, is this something that can be factored into the Blender script?

Now that you've identified how to tell how many textures go with each model and how to tell which vertices go with each texture, I should be able to someday (when I'm not so freaking busy with my current internship) program it into the script.

FaustWolf

  • Guru of Time Emeritus
  • Arbiter (+8000)
  • *
  • Posts: 8972
  • Fan Power Advocate
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #636 on: June 29, 2008, 11:09:30 am »
Suh-weet. Take your time, I've got a Chrono Trigger graphic insertion tutorial to write in the meantime, and we can also get animations figured out.

MDenham has already determined the entire header structure for animations and I've largely confirmed his findings with a tweak or two. The first frame of animations will be fairly easy to figure out I think, as the length of the first animation frame is dependent on number of bones. The succeeding frames will be a bit more difficult though. I'll post examples and Youtube videos by next weekend hopefully.

Boo the Gentleman Caller

  • Guru of Life Emeritus
  • Hero of Time (+5000)
  • *
  • Posts: 5262
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #637 on: June 29, 2008, 11:23:32 pm »
Hey FaustWolf, do you think you could cook up some simple tutorials?  You're gonna need some help as far as programming, etc. goes, so I'm hoping to start helping soon.  Tutorials would help me get started (instead of learning by trial and error).

FaustWolf

  • Guru of Time Emeritus
  • Arbiter (+8000)
  • *
  • Posts: 8972
  • Fan Power Advocate
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #638 on: June 29, 2008, 11:56:19 pm »
Boo, if you don't mind choking down some hexadecimal code and digesting it (really all I've been doing) I'd recommend that you first rip your first Chrono Cross CD according to the instructions here. You'll need a 2352 byte/sector format file (commonly referred to as BIN format), but ironically it has to be named CD1.iso to work with the dumping utility here.

If you're able to get a successful run of dump.exe according to the instructions in the linked .zip file, you'll be in a position to use further file dumping and decompression tools linked here. The instructions for ripping the appropriate game image and using the dump.exe should be sufficient hopefully, but I'll need to give you more specific instructions on using the additional tools Ramsus compiled from Yazoo's source files. Drop me a PM in case you get stuck anywhere, and I'll convert our back-and-forth into a FAQ for getting started on Chrono Cross file exploration. It's high time I did something like that anyway.

Boo the Gentleman Caller

  • Guru of Life Emeritus
  • Hero of Time (+5000)
  • *
  • Posts: 5262
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #639 on: June 29, 2008, 11:58:12 pm »
Crap.  My Chrono Cross game is in Alabama.  I won't be able to get it until next weekend.  But I will certainly get started on this ASAP.  I figure that as this project gets up and going, you're going to need more able hands involved in coding, programming, etc.  Why not have someone helping you who's been there since day one?

Schala Zeal

  • Radical Dreamer (+2000)
  • *
  • Posts: 2127
  • 7th Elemental Innate, and vtuber
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #640 on: June 30, 2008, 12:03:47 am »
In light of the day's wondrous turn of events, I'm starting a new thread dedicated to our findings regarding the files that the Ramsus/Yazoo dumper has produced. I can't very well recap everything that happened, so if you're reading this for the first time, check out the posts that start here: http://www.chronocompendium.com/Forums/index.php/topic,4729.msg83034.html#msg83034

This thread shall be dedicated to the basic findings that flow out of Ramsus' wonderful work. I've attached a number of files to this thread:

1st: The Ramsus/Yazoo dumper, which is what Zeality, Luminaire85 and I have used successfully to dump ALL of Cross' files. It's a tool originally created by Yazoo of Terminus Traductions that Ramsus modified so that it works more efficiently (and at all, in my case). Beware though, Ramsus will be making continual improvements to this program to make it even better!

2nd: More tools I received from Sephiroth 1311 in Italy. I'm not sure what's in here just yet, but there may be new tools we can use. Remember though, if there are any new tools in here, they haven't been optimized by Ramsus.

3rd: The rest of Yazoo's tools, written in C++ and compiled by Ramsus. The beauty of this is people don't have to compile themselves to check everything out since Ramsus has done that work for us. Inside you'll find all sorts of goodies including decompression utilities. To use them, run from the command line or (in my case, since I suck at command lines) simply drag the pertinent file over the .exe.

Remind me I owe you a megalixir ^_^

Schala Zeal

  • Radical Dreamer (+2000)
  • *
  • Posts: 2127
  • 7th Elemental Innate, and vtuber
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #641 on: June 30, 2008, 12:06:17 am »
Crap.  My Chrono Cross game is in Alabama.  I won't be able to get it until next weekend.  But I will certainly get started on this ASAP.  I figure that as this project gets up and going, you're going to need more able hands involved in coding, programming, etc.  Why not have someone helping you who's been there since day one?

The pSX emulator comes with a tool called cdztool. It converts PSX CD ROMs into file images. Not only that but before I got CC on CD myself, I downloaded 2 files, 700 megs each. Each file was a CD image file. It ran slow but then again, it was ePSXe that I used... ick.

FaustWolf

  • Guru of Time Emeritus
  • Arbiter (+8000)
  • *
  • Posts: 8972
  • Fan Power Advocate
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #642 on: June 30, 2008, 01:58:25 am »
Schala Zeal, did you say you were familiar with C/C++?

I've successfully used a compression/decompression utility created by Terminus Traductions on Chrono Cross' LZSS-compressed dialogue files. However, they don't work on the compressed fieldscript, perhaps because the utilities do extra things like make the dialogue game text more readable in addition to the raw compression/decompression. It is my great hope that with some minor modification of the Terminus Traductions LZSS source code, we may end up with a general LZSS compressor/decompressor as opposed to one meant specifically for the dialogue files.

halkun and Cyb, if you're reading this I should report that the Terminus Traductions tools label all LZSS-compressed files in Chrono Cross "FF7V LZS." ...does this mean what I think it does? Could Squaresoft have realistically used the exact same compression routine for two projects separated by two years in terms of release?

Anywho, for all with coding skills who are interested, I'm attaching a sample LSZZ-compressed dialogue file and its uncompressed equivalent. These are labeled 0008.OUT and 0008.txt. Also in the attachment are two non-dialogue LZSS compressed files for comparison named 0003.OUT and 0007.OUT. In a subfolder within the .zip I've attached all the souce code for the Terminus Traductions tools. LZSS.C and LZSS.H are no doubt the most pertinent. Would it be possible to make a general LZSS compressor/decompressor with this code? If any C/C++ coders are willing to take a look at it, I can broach the compression utility topic in its own thread for further discussion and exploration.

[attachment deleted by admin]

MDenham

  • CC:DBT Dream Team
  • Chronopolitan (+300)
  • *
  • Posts: 330
  • Glowsticks are not a weapon.
    • View Profile
    • Java IRC - konata.echoes-online.com
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #643 on: June 30, 2008, 02:30:25 am »
Out of curiosity, did you notice that the dialogue table for the debug room seems to be in there as well? :D

Looks like it's less of a "debug room" and more of a "debug flag"...

--

As far as the tools themselves, I'm looking at converting it to C# (nothing wrong with C++, but I should get a decent amount of experience in on C# for other things) and, incidentally, translating it to English (I know a little French, enough to be able to make out what's being said, but it's still a pain in the neck).

My initial reaction upon looking at their header files: dear God, why?!  Several "standard" includes are in every .h file.  :(  So it's not like the code couldn't stand a bit of tidying to begin with. :D

The C# route does open up another possibility for CC:DBT, though, in the future - a Windows and XB360 version.
« Last Edit: June 30, 2008, 02:37:22 am by MDenham »

FaustWolf

  • Guru of Time Emeritus
  • Arbiter (+8000)
  • *
  • Posts: 8972
  • Fan Power Advocate
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #644 on: June 30, 2008, 02:38:27 am »
Yeah, each dialogue script file contains the entire Debug Mode text as well. Seems oddly redundant to me at first glance, but as with most things in CC, I guess speed was of the essence.

What would the presence of a debug flag as opposed to a debug "room" tell us, M? I'm especially interested in the zoom function that the debug mode makes use of; my guess is the model size for each room is specified by the fieldscript, which is most likely one of the other LZSS-compressed files in each of the game's rooms.