News:

As a consequence of the forum being updated and repaired, the chatbox has been lost.
However, you can still come say hi on our Discord server!

Main Menu

Compression Formats

Started by Daddy Poi's Oily Gorillas, 20, February, 2015, 05:29:34 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

TenkaiSp

I don't really know how to do that. I mean, I know where to look, but I don't know the right values to use. The patching file in gstlatoolkit looks like this:

[spoiler]
Quoteecho Expanding ROM
patch x tla_patched.gba $01800000

echo Assembling decompress.asm
goldroad asm\decompress.asm

echo Assembling setArgumentsTLA.asm
goldroad asm\setArgumentsTLA.asm

echo Inserting decompress.asm
patch i tla_patched.gba asm\decompress.gba $0003843C

echo Inserting setArgumentsTLA.asm
patch i tla_patched.gba asm\setArgumentsTLA.gba $00038580

echo Inserting string offset table
patch i tla_patched.gba bin\offsets.bin $00FA0000

echo Inserting strings
patch i tla_patched.gba bin\strings.bin $00FAC300
[/spoiler]

Daddy Poi's Oily Gorillas

#21
Whether you choose to compress or not is up to you... Frankly, I don't think it matters unless you need the space. (Probably don't.)

I did not look at how Approxies puts the data back into the ROM... But my compressor compresses it to 0x00FA0000.... and it looks the addresses in your spoiler (gstlatoolkit) places it there too... Soo...

Quoteecho Inserting string offset table
patch i tla_patched.gba bin\offsets.bin $00FA0000

echo Inserting strings
patch i tla_patched.gba bin\strings.bin $00FAC300

With the game open in VisualBoyAdvance, you can go to Tools>Memory Viewer... in the address field... The Rom section goes from 0x08000000-0x09FFFFFF, it should match what you see when you open the file in a hex editor. So you just put 0x08FA0000 in the address field, press Go... scroll down until you find what looks like 00 data... That is unused/free data... and is the address you want to put in. (And +0xC300 for the next address.) (Assuming you're editing a hack, I recommend overwriting the text data that has already been pointed in the area if it is there. It should be easy to notice in The Balance Age since the text should be uncompressed, but I didn't check that for myself, if anything unlikely should go wrong.)

You might need to edit the same addresses in the asm files as well. (So that the game knows that the data moved.)


^^ Wrote this without checking.... but I did look into gstoolkit a long time ago, so....
Golden Sun Docs: Broken Seal - The Lost Age - Dark Dawn | Mario Sports Docs: Mario Golf & Mario Tennis | Misc. Docs
Refer to Yoshi's Lighthouse for any M&L hacking needs...

Sometimes I like to compare apples to oranges. (Figuratively) ... They are both fruits, but which one would you eat more? (If taken literally, I'd probably choose apples.)
Maybe it is over-analyzing, but it doesn't mean the information is useless.


The only GS Discord servers with significance are:
Golden Sun Hacking Community
GS Speedrunning
/r/Golden Sun
GS United Nations
Temple of Kraden

Can you believe how small the Golden Sun Community is?

2+2=5 Don't believe me? Those are rounded decimal numbers. Take that, flat earth theorists! :)

Caledor

#22
Try this: open go_TLA.bat with a txt editor and change "$00FA0000" to "$01000000" and "$00FAC300" to "$0100C300" then go into the asm folder, open setArgumentsTLA.asm in the same txt editor, and change at lines 57 and 58:
"r2,=0x08FA0000" to "r2,=0x09000000" and
"r3,=0x08FAC300" to "r3,=0x0900C300"

Save both edited files and paste your translation on a clean ROM (clean as in "not already patched with gstlatoolkit).

This way you save the uncompressed text at 01000000, which is where the original ROM ends. Basically, this way the toolkit can't overlap with anything and it'd be compatible with literally every patch you can find on this forum.

EDIT: @Fox actually in my patches the text is still compressed, I made all the changes with the editor.

TenkaiSp

Thanks guys, looks like saving the text at 01000000 gets rid of all compatibility problems  :happy: