Jump to content

Using PokeSav DP with HGSS


ReignOfComputer

Recommended Posts

I changed some things with hexediting the save file. My name for example... that stupid Japanese games won't allow me more than five characters... :( which is very odd... I've noticed that there are 7 places for the chars. Even with Japanese it's possible to have 7 characters instead of max 5.

And so I needed to change the OT in my Pokémon too... so I went to my hexeditor again... found the offsets, extracted the Pokémon, imported into Pokesav (*.bin in Party), changed my name, exported it to a bin file again and replaced it in the HG save.

It's not that hard to change it, you just need to know which block you need to edit...

Oh, and of course... the checksum must match with the edited block. Lucky me... HxD has a function to get the checksum from (a part of) the file, I just needed to know it was the CRC-16 CCITT algorithm.

Grtzz!!

Edited by Grovyle91
typo
Link to comment
Share on other sites

:eek: Really? That's some pretty good news. It'll make save research a lot easier.

You didn't know this? :eek: I thought you knew this since PPSE is in development and such. Well, glad to hear I can help you with something :D.

It's pretty a funny story how I figured this out, a while ago I wanted to manipulate the lottery in Platinum, so I needed to know the checksum algorithm xD and later I found it, changed it and it worked :biggrin:

Oh, but you need to know, even the checksum is stored in Little Endian format, so... reversed...

Btw, if you need some offsets:

Block A1: 0x00000 - 0x0F627

Block B1: 0x0F628 - 0x21A0F

Block A2: 0x40000 - 0x4F627

Block B2: 0x4F628 - 0x61A0F

Block A

Trainer name: 0x00064 - 0x00073

Trainer ID: 0x00074 - 0x00075

Secret ID: 0x00076 - 0x00077

Money: 0x00078 - 0x0007B

Gender: 0x0007C

Country of origin: 0x0007D

Badges (I'm not entirely sure, since this is based of DPPt with 8 badges, but HGSS have 16 badges): 0x0007E

Total playtime: 0x00082 - 0x00089

Current party Pokémon count: 0x00094

Party Pokémon: 0x00098 - 0x00623

Footer: 0x0F618 - 0x0F627

The footer has indeed 0x10 bytes, instead of 0x14 (DPPt).

0x00 - 0x03: Save count

0x04 - 0x07: Size of block

0x08 - 0x0B: ?

0x0C - 0x0D: ?

0x0E - 0x0F: Checksum

The checksum is calculated from a whole block without taking the footer, but I guess this is widely known to you. That's why the first 4 bytes are missing here, if you include them... you get a wrong checksum.

The wiki here was a great help too :D

Grtzz!!

Link to comment
Share on other sites

SCV did the checksum stuff for the save files, so I never really had to mess with it. I would have never expected the algorithm to be in HxD.

I already know about the block sizes, footer stuff, and the locations of all the Pokemon. The Pokemon and the Pokedex (found that too) were the first things I looked for, followed by the save footers. All that other stuff will be useful when PPSE gets around to it.

So, HGSS uses the same checksum algorithm?

Link to comment
Share on other sites

SCV did the checksum stuff for the save files, so I never really had to mess with it. I would have never expected the algorithm to be in HxD.

I already know about the block sizes, footer stuff, and the locations of all the Pokemon. The Pokemon and the Pokedex (found that too) were the first things I looked for, followed by the save footers. All that other stuff will be useful when PPSE gets around to it.

So, HGSS uses the same checksum algorithm?

Ah... alright ;) Neither did I, but it was quite handy :)

The only thing you need to be careful with, is the footer of which its length has been changed in HG/SS. For the rest, the checksum algorithm is the same I used to edit the Pt save with and HG didn't complain. So, that's a care less (or how you would say it, I'm not that good in expressions :P).

Grtzz!!

Link to comment
Share on other sites

You're right about that egg recognizing...

I've the Togepi egg now (which was hard, since I didn't know that that aide was hinding in the Mart xD). There are a few more hex values:

44h: DD

45h: 07

86h: 04

I'm pretty sure 44-45h is the location of the egg obtaining in HGSS since every Pokémon in HG I've examined has the location 3002 (Faraway place) in D/P/Pt Pokesav. This means that that aide has id 2013 or something. Also, 46-47h is the location of met then (which is odd, because Pt has 45-46h for location of met right?)

I don't know anything about 86h. All my other Pokémon also have 04 in 86h.

I guess there's some check with this location or 86h in combination with the hometown.

Usually, "That's one less thing to worry about."

Yeah, I thought so it wasn't right. It was literally translated from Dutch: "Dat is een zorg minder" :P. Even sometimes in Dutch I'm not good in such things.

so.... can i use the pokesav with HGSS?

I don't think so, it'll corrupt your save. Some offsets are the same, but the most important offset (the checksum) isn't.

Grtzz!!.

EDIT: stupid me... I forgot to change the Party amount... the egg shows up now when I correct that amount.

Edited by Grovyle91
Forgot the Party amount... :\
Link to comment
Share on other sites

I don't know anything about 86h. All my other Pokémon also have 04 in 86h.

I guess there's some check with this location or 86h in combination with the hometown.

0x86 stores the value for the HGSS ball used to capture the Pokémon. The ball location in DPPt is set to a Poké Ball if an Apricorn ball is used. This ensures compatibility between the different versions.

Nice work so far!

Link to comment
Share on other sites

0x86 stores the value for the HGSS ball used to capture the Pokémon. The ball location in DPPt is set to a Poké Ball if an Apricorn ball is used. This ensures compatibility between the different versions.

Nice work so far!

Ah... compatibility with the balls... haven't thought about that yet :)

Thanks ;)

I guess we're further than COM (for now), he just released a stripped version of the DP Pokesav.

Btw. I just saw the wiki page about the Pokémon structure. The egg/met location of Platinum matches with the HG/SS locations.

The only thing that's really new is 0x86 which should be added there.

Grtzz!!

Link to comment
Share on other sites

I just saw the wiki page about the Pokémon structure. The egg/met location of Platinum matches with the HG/SS locations.

The only thing that's really new is 0x86 which should be added there.

Not necessarily... there must be a place elsehwere in the PKM data to store the HGSS met locations, since (having tested it myself) the met location shows up as "Faraway Place" in DPPt (if caught in HGSS), which obviously wouldn't be the case in the HGSS summary screen.

Additionally, there are the Pokéthlon stats to consider. Plus, I heard that there were medals awarded to Pokéthlon winners, which are probably stored in a bitfield similarly to the Ribbons.

Link to comment
Share on other sites

Not necessarily... there must be a place elsehwere in the PKM data to store the HGSS met locations, since (having tested it myself) the met location shows up as "Faraway Place" in DPPt (if caught in HGSS), which obviously wouldn't be the case in the HGSS summary screen.

Additionally, there are the Pokéthlon stats to consider. Plus, I heard that there were medals awarded to Pokéthlon winners, which are probably stored in a bitfield similarly to the Ribbons.

Guess there'll also be something with the ApriShakes for the Pokéthlon stats of a Pokémon, just like Poffins for Contests. I think this won't be at the same location? I'm not sure, may be they do share the same offsets... I really don't know. Since I'm not that far that I can do the Pokéthlon, I haven't tested it... (stupid crashes... :()

Grtzz!!

Link to comment
Share on other sites

Guess there'll also be something with the ApriShakes for the Pokéthlon stats of a Pokémon, just like Poffins for Contests.

Exactly.

I think this won't be at the same location? I'm not sure, may be they do share the same offsets... I really don't know.

I'm sure they will be stored in a different location. It would just be silly for them to conflict.

Since I'm not that far that I can do the Pokéthlon, I haven't tested it... (stupid crashes... :()

I am playing a retail copy, but until I figure out how to backup the HGSS save files (which apparently cannot be done in the typical ways due to the new cart architecture), I will have to rely on other people to trade my PKM and inspect the resultant PKM files.

(Unfortunately, packing up and preparing to move has occupied much of my free time lately.)

Link to comment
Share on other sites

Hang on - new cart structure!? Is it because of the cart's interaction with the infrared Pokewalker? Until a solution is found it seems that AR codes are the way to go *hates Vistax64 for not accepting the ARDS*

I just hope that HG/SS don't have the same "we can only transfer half of the save" problem that Platinum did.

Link to comment
Share on other sites

Hang on - new cart structure!? Is it because of the cart's interaction with the infrared Pokewalker? Until a solution is found it seems that AR codes are the way to go *hates Vistax64 for not accepting the ARDS*

I just hope that HG/SS don't have the same "we can only transfer half of the save" problem that Platinum did.

vista x64 bits supports the ards i had it working on the old roomies comp now i have it on a windows 7 rc 64x you should check it out via manager :P

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...