ROM Hack Tutorial: Hacking the text in Pokemon DP/Pt.

Status
Not open for further replies.

mehrab2603

Well-Known Member
Member
Joined
Sep 29, 2008
Messages
363
Trophies
1
Location
Edmonton
XP
1,844
Country
Canada
Rykin could you kindly post your compiled poketextds please.I compiled the source code of poketextds but when i tried to run the program it gives me an error message and closes the program.
 

kazumi213

Well-Known Member
Member
Joined
Oct 16, 2006
Messages
293
Trophies
0
XP
75
Country
Rykin said:
More advanced process:
(...) Poketext comes with a table file, so you can use your preferred script editor to modify (...)

Hi Rykin.

Which (hex) editor accept 2-byte character replacement tables coded using UTF as the one supplied in the PokeTxt distribution? I know Windhex allows 2-byte character tables, but they must be coded in S-JIS.

Thanks in advance.
 

Rykin

Well-Known Member
OP
Member
Joined
Feb 15, 2004
Messages
408
Trophies
2
Age
40
Location
Baltimore, MD
Website
Visit site
XP
819
Country
United States
As some of you may have noticed, I never continued this tutorial into more advanced methods. This is because I became annoyed at certain people and decided "Screw it. You can figure it out for yourself".

@mehrab2603
No. Go read some C++ Tutorials. You'll figure it out.

@kazumi213
I couldn't find any that I liked. I just use hex workshop (I changed the character display settings) and manually added in the extra value. I sometimes forget to do this and that's how many of the ????? typos showed up.
 

upbumpo190

Well-Known Member
Member
Joined
Jun 9, 2007
Messages
168
Trophies
0
Location
The 5th dimension
Website
ethericwarriors.eu
XP
101
Country
France
@Rykin

I fixed the PokeText source, and have it compiled and ready to re-encrypt, but I have one question, with the poketext.exe program how to we get it to re-encrypt upon execution? I havel my unencrypted bin files ready. I read somewhere that the file I want to re-encrypt has to be named dec.dat. But I am unsure, as I have tried this, placing it in various locations, to no avail. It must be me doing something wrong. I am not asking for help with the (C++) source code, so don't worry.

Sorry to have offended you earlier on,

Chris

Edit:
I see you have requested this thread to be closed. Permission to pm?
 

upbumpo190

Well-Known Member
Member
Joined
Jun 9, 2007
Messages
168
Trophies
0
Location
The 5th dimension
Website
ethericwarriors.eu
XP
101
Country
France
@Rykin
I tried what you said, and I have one .exe decrypting to .bin, and I have this one to encrypt, but I get various C++ syntax errors when compiling. I'm not the best at this, so if anyone can point out my mistake(s), it would be appriciated.

Chris

EDIT2:
I re-updated the code with a line of code, that gets rid of the errors ("fpout" undeclared indentifier).
It successfully compiles, but I get one warning, which is the cause of crash upon launch.
It is:

warning C4700: uninitialized local variable 'data16' used
warning C4700: uninitialized local variable 'fpout' used

Here is the updated code.
CODE
int main(int argc, char *argv[])
{

int sze;

u16 *data16;
u32 *data32;
FILE *fp;
FILE *fpout;
char filename[20];

for(int i=0; ichars, i+1, data16+(((sdptr+i)->Ptr)/2), fpout); // encrypt Txt
DecyptPtrs(*data16, *(data16+1), sdptr); // and ptr


sprintf(filename, "done\\%03d.bin", i);
fpout = fopen(filename, "wb");
fwrite(data16, 1, sze, fpout);
fclose(fpout);
free(data16);
}
}
 

Rykin

Well-Known Member
OP
Member
Joined
Feb 15, 2004
Messages
408
Trophies
2
Age
40
Location
Baltimore, MD
Website
Visit site
XP
819
Country
United States
One major thing I notice is that DecyptTxt() no longer has a for() loop, yet it's still calling the variable in the loop (i).

As your code is right now, it /may/ re-encrypt the header, but it won't touch the actual text.

Okay... here's the big hint.
Take the decrypter. Remove the HTM output. If that works, move to the next step.

The encrypter has one major difference from the decrypter.
The call for DecyptTxt() comes before DecyptPtrs() in the encrypter.

What compiler are you using?
 

upbumpo190

Well-Known Member
Member
Joined
Jun 9, 2007
Messages
168
Trophies
0
Location
The 5th dimension
Website
ethericwarriors.eu
XP
101
Country
France
Thanks again for your help, I'll keep working on it, I think I mixed up a few things. So off I go again, but for now, I think I'll just watch a movie.

If you ever decide to release your project to someone willing to continue it, I would be more than happy to take the job, as I have the time and the patience, needed.

Btw, happy late birth-day, sorry for the lateness.
smile.gif


Chris
 
Status
Not open for further replies.

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    K3Nv2 @ K3Nv2: What every rich scumbag thinks that they can put their dick on anything and get away with it