(Link to AcmlmWiki) Offline: thank ||bass
Register | Login
Views: 13,040,846
Main | Memberlist | Active users | Calendar | Chat | Online users
Ranks | FAQ | ACS | Stats | Color Chart | Search | Photo album
04-20-24 09:04 AM
0 users currently in ROM Hacking.
Acmlm's Board - I3 Archive - ROM Hacking - Decompressing graphics New poll | |
Pages: 1 2Add to favorites | Next newer thread | Next older thread
User Post
Jahakob



 





Since: 01-05-06

Last post: 6675 days
Last view: 6675 days
Posted on 01-05-06 09:44 PM Link | Quote
Hello there, I know the basics of translating and I could translate the whole Secret Of Mana (to swedish) completely if it weren't for that damned compressed graphics.

Some icons (with some text in them) and the nintendo-logo are compressed and I want to edit them. I've been looking around for "How-to-decompress-graphics-guides" but very often they are way too complex or I can't get the outdated software to work on winXP.

Please help me, what should I do? If you want to take a look at the rom I'm talking about, get Secret Of Mana (E) [v 1.1]. I'd love to get an easy guide though I doubt they exist...
JLukas

Goomba


 





Since: 11-19-05
From: USA

Last post: 6421 days
Last view: 6421 days
Posted on 01-05-06 10:57 PM Link | Quote
Lunar Compress has support for Secret of Mana (not sure if the game uses more than one format):

http://fusoya.panicus.org/lc/index.html

to use it, you would open a command prompt and type:

decomp.exe som.smc filenametosaveas xxxxxx 6 0

where xxxxxx is the start offset in the file to decompress


(edited by JLukas on 01-05-06 10:01 PM)
(edited by JLukas on 01-06-06 08:56 PM)
TFG
Newcomer


 





Since: 12-13-05

Last post: 6678 days
Last view: 6678 days
Posted on 01-06-06 01:12 AM Link | Quote
http://agtp.romhack.net/dmalog/ <- All you need to know
Heian-794

Red Paratroopa


 





Since: 01-02-06

Last post: 6271 days
Last view: 6305 days
Posted on 01-06-06 05:18 AM Link | Quote
Anyone ever mess around with the third Baseball Simulator 1.000 sequel? It's a really nice-looking game, and I want to translate it, but many of the graphics, and more importantly, fonts are compressed and I can't do anything with it. This is one of the best SNES baseball games and deserves to be translated/hacked.
Jahakob



 





Since: 01-05-06

Last post: 6675 days
Last view: 6675 days
Posted on 01-06-06 12:16 PM Link | Quote
Thank you an eternity for your replies.

"http://agtp.romhack.net/dmalog/" is too complicated. The software they use doesn't work for me and I don't know anything about loading and storing data by using ASM.
They also loose me at this point:

"[03:06] <@RadioSprite> alright, now the piece you want is the battle font, right?
[03:06] <@RadioSprite> the 8x8?
[03:06] yeah.
[03:06] 2bpp, 8x8.
[03:06] <@RadioSprite> Use whatever you want, it shouldn't make much of a difference.
[03:06] <@RadioSprite> just so long as you can get a zsnes format savestate out of it.
[03:06] k.
[03:08] <@RadioSprite> Okay well, this is going to be a little bit tough.
[03:08] * Looking up Naoya user info...
[03:08] <@RadioSprite> My first try when saving state turned up the font at $2CC13.
[03:08] <@RadioSprite> Now the time for savestate layout lesson."

What program is he using, where does he see this text?

JLukas, I've tried for many good hours now to get it to work. At best I can create a file but with no data in it. At most I got one symbol: ¨ .

decomp.exe Secret.smc decom.smc 3F216F 6 0



I don't know how offset works and I have no idea hwo to find it or what to write, '3F216F' is just a wild guess just to see if I could get it to work...
Please give me a guide how to find the compressed data and it's offset or do it for me, if you know. *hint hint*

I really appreciate your help, thank you.
TFG
Newcomer


 





Since: 12-13-05

Last post: 6678 days
Last view: 6678 days
Posted on 01-06-06 03:57 PM Link | Quote

...I don't know how offset works and I have no idea hwo to find it or what to write...


I highly suggest you attempt something easier for now. Figuring out compression schemes requires (99% of the time) knowledge about the console's hardware. Get Geiger's SNES9x debugger, it's probably the best debugging tool for SNES out there. Also, you can find a myriad of documents on intermediate and advanced romhacking documents here.

Good luck.
Jahakob



 





Since: 01-05-06

Last post: 6675 days
Last view: 6675 days
Posted on 01-06-06 05:46 PM Link | Quote
That's the problem, huh? You want to do this little change that takes at most 5 minutes to do (or so I've read) but first you have to learn how to program that 65816 processor or whatever...
It's really hard, I have a hard time with the terminology (that is english, on the top) and the documents that exists presume you have done something similar or that you are at least familiar with the programming-bit, 6052-programming or something in that line.

I'd love to start _liking_ programming and hacking but right now it just gives me a head-ache. I don't understand a flying fuck and the word 'programming' really scares me.

I'll leave it as this; if someone want to help me decompressing the graphics, tell me what I should write in Lunar Compress and I'll give you credits in the swedish translation, it's basicly finished. I want to edit the icons in-game (equip, status and those) and the nintendo logo in the start, that's all. At the same time I will be trying to learn assembly hacking but since THAT will take months or something I really need your help, right now.

Thank you for the replies, TFG.
JLukas

Goomba


 





Since: 11-19-05
From: USA

Last post: 6421 days
Last view: 6421 days
Posted on 01-06-06 09:55 PM Link | Quote
Originally posted by Jahakob
JLukas, I've tried for many good hours now to get it to work. At best I can create a file but with no data in it.


That's because you need to know the exact offset of where the compressed data is first.

I looked in the debugger quick. The compressed packet containing the logo is at 1CE800

You would type this (game must not have the $200 byte header):

decomp.exe som.smc title.smc 1CE800 6 0

It should say Compressed Size: 8BA and Uncompressed Size: C00

Then open the title.smc file in a SNES graphics editor to edit.

After you're finished, back in LC type

recomp.exe title.smc som.smc 1CE800 6 0

Important: when it's placed back in, your new compressed packet must say "Compressed Size: 8BA" OR LESS, or else it will overwrite other data in the game (very bad)


(edited by JLukas on 01-07-06 03:53 PM)
Jahakob



 





Since: 01-05-06

Last post: 6675 days
Last view: 6675 days
Posted on 01-07-06 09:06 AM Link | Quote
God, thank you JLukas, that is EXACTLY what I hoped for, thank you.

Unfortunately, it doesn't work for some reason...
I'll send you some pictures if that would help you out, thank you again for your help, it's really.... helpful.

1. Here is the directory, everything is there, as you can see. I've named the .bat-file 'decompressmana.bat'.



2. This is what I've wrote in it. That's right, isn't it?



3. I run it, but the 'compressed size' and 'decompressed size' got the wrong numbers.



4. I open my newly created title.smc with notepad...



5. ... with my hexeditor, translhextion...



6 ... and the only tileeditor I got that actually CAN open the document shows nothing. Nothing was written to the file, obviously.



7. Here is some information about the Secret of Mana-game I used when decompressing.



Can you make something out of this? I hope you can, if not, ask away about what you need to know. You've been a great deal of help JLukas so I thank you again.


(edited by Jahakob on 01-07-06 08:11 AM)
MathOnNapkins

1100

In SPC700 HELL


 





Since: 11-18-05

Last post: 6270 days
Last view: 6270 days
Posted on 01-07-06 09:31 AM Link | Quote
My guess would be to try 1CE800, as 1CE8000 is too large an offset for any SNES game (24 bit addressing). I think he made a typo.
Jahakob



 





Since: 01-05-06

Last post: 6675 days
Last view: 6675 days
Posted on 01-07-06 01:02 PM Link | Quote
Wow, thank you. It worked. Thaaank you, both of you! I owe you so much, thank you.



It says 'Swedish version'.

If I get the icons in game this whole decompressing-bit would be over with.



Thank you once again. =)
JLukas

Goomba


 





Since: 11-19-05
From: USA

Last post: 6421 days
Last view: 6421 days
Posted on 01-07-06 04:58 PM Link | Quote
Thanks for catching the mistake MoN

I tried to find the icons, but that one is beyond my ability. I can't find where it's getting the data from, but it's compressed as far as I can tell. It may or may not use the same compression routine as the title screen.
Jahakob



 





Since: 01-05-06

Last post: 6675 days
Last view: 6675 days
Posted on 01-07-06 07:28 PM Link | Quote
Oh, okay. That's a shame...
Maybe you could tell me how you found the title-screen info? With printscreens or something? I got that snes9x-debugger, if that is what you're using. I know I'm asking for much but it would be very helpful.
If they are compressed the same way I maybe could find them somehow, if I look through large parts of the rom?
Thank you in advance, JLukas, you have been very helpful either way.


(edited by Jahakob on 01-07-06 06:28 PM)
ChaoJeff482

Micro-Goomba


 





Since: 11-21-05
From: Kent, Washington

Last post: 6477 days
Last view: 6271 days
Posted on 01-07-06 09:57 PM Link | Quote
Well I have tested it out, but it seems Windows refuses to do the command correctory and keeps giving me a message that keeps saying "is not recognized as an internal or external command"

Or am I doing this whole thing wrong, such as I have to create a notepad file in order to for the decomp.exe program to read the directory?
JLukas

Goomba


 





Since: 11-19-05
From: USA

Last post: 6421 days
Last view: 6421 days
Posted on 01-08-06 12:48 AM Link | Quote
I found the icon offsets. They are 96 bytes each, the first 48 of which contain the icon text:

128760 1287BF EQUIP icon

12C360 12C3BF Targeting icon
12C3C0 12C41F STAT icon
12C420 12C47F LEVEL icon
12C480 12C4DF ACT icon
12C4E0 12C53F EDIT (controller) icon
12C540 12C59F EDIT (window) icon

In VRAM, the range is from DC00-DFFF (there's one other unrelated icon in there, too.)

The problem is that there is some sort of compression (not the same as the title screen) - the icons don't appear correctly in a graphics editor.

For anyone interested in looking at the routines, the routine that loads the icons into RAM is at D0CA8B-D0CAB6. The decompression routine follows.

You might want to try changing around the hex values to see if you can figure it out. If you place FF for all the first 48 bytes, it won't display any text above the icon graphic.
Jahakob



 





Since: 01-05-06

Last post: 6675 days
Last view: 6675 days
Posted on 01-08-06 08:43 AM Link | Quote
So you're saying that I wont be able to decompress it with Lunar Compress? Well, anyway, I can't. I get "Either decompression failed, the format isn't supported, or the compressed structure has a size of 0" so I think you're saying that I can't use this program anymore...

Zsnes and snes9x can decompress the graphics, why is it impossible to build some kind of decompressor based on that technology? I'm not complaining, I'm just curious.

Thank you, anyway. You've actually found it and that should be worth something, right?
MathOnNapkins

1100

In SPC700 HELL


 





Since: 11-18-05

Last post: 6270 days
Last view: 6270 days
Posted on 01-08-06 04:57 PM Link | Quote
The "technology" as you put it, is probably something any working SNES emulator would have. Why? okay let me try to explain this. The processor on the SNES has no built in graphics compression. So when you program a game, you have to manually code functions that will decompress the tiles and put them into memory. Some types of compression are more common than others, and hence become easy to recognize across different games.

When something like Lunar Compress is built, it is built to handle most types of decompression/recompression. But the way a programmer compresses his graphics is up to him - it doesn't have to be any algorithm people already know about. I looked at the code last night and it does appear to be decompressing it, but I didn't have time to go in depth last night, and i have to go to work right now.... so you'll have to wait until then. I might be able to make a quick program to work on them.
Jahakob



 





Since: 01-05-06

Last post: 6675 days
Last view: 6675 days
Posted on 01-08-06 05:50 PM Link | Quote
I see, the game decompresses itself to the memory, it's not the processor that does it. So you have to find the way it is compressed and how it decompresses itself in the rom, not the snes-processor. Am I right? Possibly not, but at least I understand that it doesn't work if the decompressor isn't hand-made for that particular game.

It would be amazing if you could create a program that can do that. I'm gobsmacked, I never thought that I would get this kind of help. You've all been very patient and helpful, thank you once again, I can't say that enough, can I?
HyperHacker

Star Mario
Finally being paid to code in VB! If only I still enjoyed that. <_<
Wii #7182 6487 4198 1828


 





Since: 11-18-05
From: Canada, w00t!
My computer's specs, if anyone gives a damn.
STOP TRUNCATING THIS >8^(

Last post: 6271 days
Last view: 6271 days
Posted on 01-09-06 12:00 AM Link | Quote
Well, no, not quite. The SNES processor runs the program code that decompresses the graphics. However, it also does almost everything else from checking the controller to making you die when you touch something bad to what the hell ever. It's essentially impossible for the emulator to know what task each piece of code performs. To write an actual decompressor you need to examine the code that does it (or figure out the format) and write a program that does the same.
MathOnNapkins

1100

In SPC700 HELL


 





Since: 11-18-05

Last post: 6270 days
Last view: 6270 days
Posted on 01-09-06 04:23 AM Link | Quote
Bleh... that turned out uglier than expected. I got sort of wrapped up in this and said, hey, why not just extract all the icons that are available? So figuring out how the icon sets were split up was what I looked at next. I was also sort of wrong about how they were compressed. It's a little funkier than what I said earlier.

[update]

Anyways I'm about 90% done with a program that will do this. It's funny b/c if I don't mess with the ASL, ROL, and other crap, it still decompresses fine, but the color indices are slightly different. If you're willing to make a backup and stick with the colors the original uses, it might not be so hard to recompress or decompress this stuff.


(edited by MathOnNapkins on 01-09-06 03:34 AM)
(edited by MathOnNapkins on 01-09-06 06:30 AM)
(edited by MathOnNapkins on 01-09-06 09:22 AM)
Pages: 1 2Add to favorites | Next newer thread | Next older thread
Acmlm's Board - I3 Archive - ROM Hacking - Decompressing graphics |


ABII

Acmlmboard 1.92.999, 9/17/2006
©2000-2006 Acmlm, Emuz, Blades, Xkeeper

Page rendered in 0.023 seconds; used 445.16 kB (max 569.19 kB)