+  RHDN Forum Archive
|-+  Romhacking
| |-+  ROM Hacking Discussion
| | |-+  Seiken Densetsu 3 decompression (source code here)
Pages: [1]
Author Topic: Seiken Densetsu 3 decompression (source code here)  (Read 1 times)
giangurgolo
Guest
« on: March 16, 2011, 12:33:34 am »

I wrote a .NET program which draws and displays the levels in Seiken Densetsu 3. It's a WIP build, and unstable so don't try to edit anything. You can move between level indexes with no problems, though. All 1114 levels draw flawlessly as far as I know, and you can export all levels as images too. I'm only releasing this if anyone out there is willing to reverse engineer the decompression code and make recompressing and saving maps possible. If it never happens, no big deal. In case anyone can expand on this, they're welcome. I'm probably not going to work on this anymore because it's just way too much work, way more than I should be willing to invest time in (more than I already have, at least).

Here is the ROM map. Almost all offsets documented are level-related.
Here is the build: http://home.comcast.net/~giangurgolo/MAPJESTER.zip
Here is the source (the reason for this thread): http://home.comcast.net/~giangurgolo/MAPJESTER_v1.0_20110316_001131.rar

Note that this is a WIP build, not even a beta, so it is not capable of saving. I put an architecture exporting feature which lets you export all the elements of a map into a single file and import it into another game. Lazy Shell v3.5 has the import option available (not released to public yet). Video demonstration of architecture porting.

The decompression is in the Comp.cs file (in the Static folder). SD3 has at least FOUR different compression formats (one each for level graphics, tilesets, solidity, and tilemaps), and possibly more but only these four are used in levels. Ignore the compression code at the beginning of the file (it's for FF5); the 4 SD3 decomp functions are obvious (marked by _SD3). Commented lines are the ASM addresses converted into C#; some functions are named based on the offset of subroutines used by the 4 decomp functions. DP_## variables are named based on the direct page registers in the 65816 asm. The buffer array is where the decompressed data is stored and used by the program. I tried simplifying the code from the ASM to C# conversion as much as possible.
obscurumlux01
Guest
« Reply #1 on: March 19, 2011, 10:53:18 pm »

DeJap Translations did the English translation for this game.  If they're still around, might wanna talk to them, as they'd know all about the compression used for SD3.  Even with 'text only' translations, they often figure out the graphics part as well, if only to edit the title screen (like in Tales of Phantasia).

As for how to get in touch with them, I really don't know for certain, google is your friend.
Azkadellia
Guest
« Reply #2 on: March 19, 2011, 11:02:53 pm »

Unfortunately, DeJap translations is dead. This post explains everything: http://board.zsnes.com/phpBB3/viewtopic.php?f=7&t=2010
I.S.T.
Guest
« Reply #3 on: March 20, 2011, 09:24:54 am »

Also, DeJap did not translate this. >_>
Azkadellia
Guest
« Reply #4 on: March 20, 2011, 03:59:09 pm »

Right. Neill Corlett hacked it and SoM2Freak, Lina`chan, and Nuku-nuku translated.
obscurumlux01
Guest
« Reply #5 on: March 20, 2011, 10:21:05 pm »

Forgive me for the misinformation then, I didn't realize that DeJap was gone.  I also didn't realize that SD3 was done by another team.  >_<
Anyhoo, contact those guys who did SD3 and ask em, if they're still around.
KingMike
Guest
« Reply #6 on: March 20, 2011, 10:28:54 pm »

Here's his homepage. Hasn't been updated since last year, but it seems he only updates every couple of years anyways. Cheesy
magno
Guest
« Reply #7 on: April 16, 2011, 02:44:11 pm »

Really interesting!! I donwloaded the app to test it.

I also translated the game into Spanish and did my own tool to recompress graphics, move data blocks, recode the Huffman tree and some other issues which make the tool specially suitable for translating the game into other languages (in fact, some translations are currently being done with my tool: german, russian, swedish...)

I had to code routines to compress and decompress graphics (for the 4 compression schemes), and I could send them to you is you are interested on them. They were wrote in C.
Pages: [1]  


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