HELP! DIFFERENT LOAD ADRESS AND DECRUNCH

General Programming help in C, C++ or ASM, Compiling / Debugging, and R3000A Central Processing Unit (CPU) information
Post Reply
Rabatini
Interested PSXDEV User
Interested PSXDEV User
Posts: 8
Joined: Nov 04, 2020

HELP! DIFFERENT LOAD ADRESS AND DECRUNCH

Post by Rabatini » October 22nd, 2021, 1:23 am

Hello Dear Fellows.

I use to make splash for my translations, to warning people to not buy games translated because its free patch.
Well, i did a lot of splash with no problem, but now, i have find one specifically game that i just cant redirect EXEC ADRESS.

THIS IS THE MAGIC PSX PATCHING INFO:
OF MY EXE

=============================
Magic PSX Patching Tool v0.1
-----------------------------
(c) 2000 - AVH of PARADOX
=============================

Load address...........: 0x80080000
Decrunch to............: 0x8007f800
Exec address...........: 0x80140324

The load address its different so as Decrunch, well.

I did changed in my .bat

ccpsx -O3 -Xo$80080000 MAIN.c data/*.obj depack.obj -oMAIN.cpe

And in my depack.src changed te decrunch as well to

idest equ $8007f800 ;Decrunch to

and finally change the exec junmp adress my main.c to

asm("j 0x80140324"); // ExecAdresse to run the Game

My splash works fina in the game, but when i try to press x to make the jump to the game its crashs.

someone can help?

Some games are icompatible with RNC compression?

thank you!!

User avatar
inc^lightforce
Verified
Psy-Q Enthusiast
Psy-Q Enthusiast
Posts: 248
Joined: Mar 07, 2013
I am a: Programmer Windows+PS1, GFX Artist
PlayStation Model: Black
Location: Germany

Post by inc^lightforce » October 26th, 2021, 2:59 am

"Some games are icompatible with RNC compression?" ----> NO

please do not forget:


1. copy the original psx exe from the image to your folder
2. rename the exe to game.rnc
3. start the dolct.bat next to dolct.exe (it create a *.txt) (read my workshop for the steps)

in this *.txt file you see the load address and decrunch to.
normally it is always the same decrunch to exec: 0x8000f800, paste this in the depack.src

the load address for the batch: better using the value from the patchdata.txt
0x80010000

do not forget all this lines in your main.c:
//-------PATCH PROCEDURE - DEPACK THE GAME-------
//-------------------------------------------------------------
EnterCriticalSection();
depack1();
start1();
ExitCriticalSection();
//-------------------------------------------------------------
//************************* starts game ***********************
//-------------------------------------------------------------
asm("nop");
asm("j 0x8008656c"); // ExecAddress --> Load Game after PAD BREAK
asm("nop");


which game do you try to patch with an intro?
can you send the original untouched psx exe from the game please. i will have a look.

and when you're done with your patch, do not forget to resize the patch including your code to the original file size of the untouched game exe. IT MUST BE EXACT THE SAME SIZE!

i always use Fileres.exe

If a game have a copyprotection you see the values also in the patchdata.txt it looks like this:

Debug-Protection at....: 0x80096554 (NOP out)
0x80096558 (NOP out)

Hook Magickey finder at: 0x80096838 (0x08003C00)

Insert Magic-Key at....: 0x80096830 (0x34C6xxxx)

Anti-ModChip protection: 0x80096810 (NOP out)
0x80096818 (NOP out)
0x80096820 (NOP out)


if you see this, you must also crack the libcrypt protection.

and not to forget:
add the pal and ntsc values into your main.c

X Button need the values from the patchdata.txt for PAL
O Button need the values from the patchdata.txt for NTSC

if you don't wanna play it in ntsc mode because the game is PAL and wanted to play only in PAL mode, you can leave the values and add a command: break; under the X button

and so on.

now add the psx exe back into the game bin. you can use cdmage. this tool make things automatically. i never used it.



if you fail again. maybe you send me your complete coding folder including the game cue and game bin.

and here is a example what you must include in your compile batch:

"...
asmpsx /l/oat- depack.src,depack.obj
ccpsx -O3 -Xo$80100000 main.c depack.obj call your objects and add -omain.cpe
:: if -Xo$80100000 is too high use -Xo$80010000
cpe2x main.cpe
del main.cpe
ren main.exe patch.psx
exefixup.exe patch.psx
del depack.obj
rename patch.psx to the original game psx exe name (SLUS.001) or so

thats it for the moment

Rabatini
Interested PSXDEV User
Interested PSXDEV User
Posts: 8
Joined: Nov 04, 2020

Post by Rabatini » November 7th, 2021, 4:30 am

Good day for you all guys!

soo, i did some comparisions and i observe that.

some games RNC makes a big compression, like the archive is 1.8mb goes to 230kbs. all games that do that, the jumper do not work.

An another observation is the given informartions by the LCT.
examples here

jump intro to game that works!
WORKS
CROSSROAD CRISIS
Load address...........: 0x80010000
Decrunch to............: 0x8000f800
Exec address...........: 0x80010008

WORKS
DINO CRISIS SPANISH
Load address...........: 0x80010000
Decrunch to............: 0x8000f800
Exec address...........: 0x800121d4

GAMES THAT DONT WORK
DON'T WORK
GALERIANS USA
Load address...........: 0x80023000
Decrunch to............: 0x80022800
Exec address...........: 0x80165f84

DON'T WORK
GUNNER'S HEAVEN
Load address...........: 0x80080000
Decrunch to............: 0x8007f800
Exec address...........: 0x80140324
must have to do with memory limits?
console thing? MAYBE?

there has any solution for this.
maybe Have any possible to help me, making a way to jump without RNC compression?

because we/I can use PSX-MODE2 TOOL to put the new oversized file replace the old psx-exe,

PSX-MODE2 can insert and rebuild all ISO.

I dont know with you guys knew this amazing tool.

here is https://www.romhacking.net/utilities/1417/

Thank you!


.

User avatar
inc^lightforce
Verified
Psy-Q Enthusiast
Psy-Q Enthusiast
Posts: 248
Joined: Mar 07, 2013
I am a: Programmer Windows+PS1, GFX Artist
PlayStation Model: Black
Location: Germany

Post by inc^lightforce » January 11th, 2023, 7:29 am

Load address...........: 0x80023000

just simple use another address in your Batch. 80100000 or 80010000. To me, 80900000 worked too in some games.
Last edited by inc^lightforce on January 12th, 2023, 10:59 pm, edited 1 time in total.

User avatar
inc^lightforce
Verified
Psy-Q Enthusiast
Psy-Q Enthusiast
Posts: 248
Joined: Mar 07, 2013
I am a: Programmer Windows+PS1, GFX Artist
PlayStation Model: Black
Location: Germany

Post by inc^lightforce » January 12th, 2023, 6:19 pm

inc^lightforce wrote: January 11th, 2023, 7:29 am Load address...........: 0x80023000

just simple use another address in your Batch. 80100000 or 80010000. To me, 80900000 worked too in some games.
this is an correction of my post. i maybe typed a wrong address. you should better try: 80090000

over and out

Post Reply

Who is online

Users browsing this forum: No registered users and 7 guests