ROM Hack PSSE - Pokemon Shuffle Save Editor

supercarotte

Well-Known Member
Member
Joined
May 21, 2015
Messages
691
Trophies
0
Age
30
XP
948
Country
France
Ah i see, great. :)

So how would someone start reverse engineering a save file?
Easiest way would be to compare save files (same save file with something changed) in a hex editor?

Exactly, that's how it's done. You make a bunch of savefiles for a bunch of different situations, hopefully with an idea of how the things will be different between them, you compare them to select offsets that could reflect these changes then you edit these offsets to check if that's what you are searching for. Once you have found the right offsets, you can edit them to make more savefiles and hopefully find how is the data you're searching for stored in them. It's like a mastermind game, except you have unlimited guesses :)

Also, I think that savedata.bin is quite easy to reverse-engineer, because once you are used to endianness (everythink is read backwards bytewise) it's pretty straight-forward.
 

Grim Ripper

Well-Known Member
Member
Joined
Jan 25, 2016
Messages
256
Trophies
0
XP
325
Country
Greece
Hmm i may try it sometime.
I'd like to make my own editors for games but i still have a long way before that. :P

Technically the closest i have done to finding stuff is psp cheats for items, then again it's easier/faster there since you scan the memory for changes.
 

nic0lette

Well-Known Member
Newcomer
Joined
Feb 5, 2016
Messages
70
Trophies
0
Age
40
XP
100
Country
United States
I wonder if people might be able to check out their save file, at the first 16 bytes or so, and then 'like' this post if they're:

09 00 00 00 40 00 00 00 ff 58 00 00 3f 59 00 00

I'd particularly be interested if someone has an old save from before the last update still around and could check that one as well.
Thank you!

EDIT: I pushed an alpha release that includes @supercarotte's updates for the new Pokémon and bulk edits with a few minor tweaks.

Please let me know if anything breaks, and make sure to backup before using it. It didn't look like it did anything horrible to my save but I really didn't try much. So, yes. Very alpha. Much bugs probably.
 
Last edited by nic0lette,
  • Like
Reactions: Smynos

Grim Ripper

Well-Known Member
Member
Joined
Jan 25, 2016
Messages
256
Trophies
0
XP
325
Country
Greece
I have a save file from before the update, i can upload it to Dropbox and give it to you over pm.

I'll be able to do it in about 6-7 hours cause i'm in class right now without my laptop. :P
 
  • Like
Reactions: Madridi

supercarotte

Well-Known Member
Member
Joined
May 21, 2015
Messages
691
Trophies
0
Age
30
XP
948
Country
France
I wonder if people might be able to check out their save file, at the first 16 bytes or so, and then 'like' this post if they're:

09 00 00 00 40 00 00 00 ff 58 00 00 3f 59 00 00

I'd particularly be interested if someone has an old save from before the last update still around and could check that one as well.
Thank you!

EDIT: I pushed an alpha release that includes @supercarotte's updates for the new Pokémon and bulk edits with a few minor tweaks.

Please let me know if anything breaks, and make sure to backup before using it. It didn't look like it did anything horrible to my save but I really didn't try much. So, yes. Very alpha. Much bugs probably.

My latest savefile has the exact same bytes, and so does a bunch of backups I found that are from march 8th (don't know what version that is though).

Thanks for pushing in my commits, like you said it's an alpha and I mostly need to check the edited "All Max Lvl" code doesnt work badly with hacked numbers of lollipops.
 

Madridi

Card Collector
Member
Joined
May 9, 2008
Messages
3,562
Trophies
2
Age
38
Location
Doha
XP
3,071
Country
Qatar
I wonder if people might be able to check out their save file, at the first 16 bytes or so, and then 'like' this post if they're:

09 00 00 00 40 00 00 00 ff 58 00 00 3f 59 00 00

I'd particularly be interested if someone has an old save from before the last update still around and could check that one as well.
Thank you!

EDIT: I pushed an alpha release that includes @supercarotte's updates for the new Pokémon and bulk edits with a few minor tweaks.

Please let me know if anything breaks, and make sure to backup before using it. It didn't look like it did anything horrible to my save but I really didn't try much. So, yes. Very alpha. Much bugs probably.
I have a few old save files to check for you when I'm back on Sunday.

Thanks for the Alpha release. Is there a change log you can share?

Thanks!
 

supercarotte

Well-Known Member
Member
Joined
May 21, 2015
Messages
691
Trophies
0
Age
30
XP
948
Country
France
I have a few old save files to check for you when I'm back on Sunday.

Thanks for the Alpha release. Is there a change log you can share?

Thanks!

It's in the commit. I updated the resource files (hopefully this time for good), fixed some issues that went along these changes, updated the Cheats section and made it so that "All Caught Lvl 10" sets level to max according to the number of lollipops currently used on that pokemon instead.
 
  • Like
Reactions: Madridi

Madridi

Card Collector
Member
Joined
May 9, 2008
Messages
3,562
Trophies
2
Age
38
Location
Doha
XP
3,071
Country
Qatar
It's in the commit. I updated the resource files (hopefully this time for good), fixed some issues that went along these changes, updated the Cheats section and made it so that "All Caught Lvl 10" sets level to max according to the number of lollipops currently used on that pokemon instead.
Thanks, glad to hear that it didn't enable stuff that it shouldn't, so that online isn't ruined.

I assume the method to have ANY Pokemon up to level 15 is also removed yeah?

Lastly, the experience update according to the levels, was that figured out or not yet?

Thanks again :)
 

supercarotte

Well-Known Member
Member
Joined
May 21, 2015
Messages
691
Trophies
0
Age
30
XP
948
Country
France
Thanks, glad to hear that it didn't enable stuff that it shouldn't, so that online isn't ruined.

I assume the method to have ANY Pokemon up to level 15 is also removed yeah?

Lastly, the experience update according to the levels, was that figured out or not yet?

Thanks again :)

Yeah I obviously would never simplement that^^
It has been figured out where experience is stored, but the amount of XP needed to reach a lvl depends o the base atk of the Pokemon and we don't know where that is stored in the game' files.
 
  • Like
Reactions: Madridi

Madridi

Card Collector
Member
Joined
May 9, 2008
Messages
3,562
Trophies
2
Age
38
Location
Doha
XP
3,071
Country
Qatar
Yeah I obviously would never simplement that^^
It has been figured out where experience is stored, but the amount of XP needed to reach a lvl depends o the base atk of the Pokemon and we don't know where that is stored in the game' files.
Glad to hear it hasn't been implemented, although some people did figure it out themselves and used it in the latest competition (The top 5 or something).. But that's really insignificant if it's just a few users.

Thanks for the update about the experience. Yeah the base power determines how much exp is needed per level. I hope that this is eventually figured out.

Thanks again!
 

supercarotte

Well-Known Member
Member
Joined
May 21, 2015
Messages
691
Trophies
0
Age
30
XP
948
Country
France
@supercarotte :-) thanks for wworking for an update for psse... anyway, does the updated app stable? any idea on when it will be released? thanks and have a nice day...

EDIT: I pushed an alpha release that includes @supercarotte's updates for the new Pokémon and bulk edits with a few minor tweaks.

Please let me know if anything breaks, and make sure to backup before using it. It didn't look like it did anything horrible to my save but I really didn't try much. So, yes. Very alpha. Much bugs probably.

A release has been made by nic0lette so you can use it. It should be stable but hasn't been tested enough yet, so for safety reasons keep a backup of your file and report to us if anything goes wong.
 
  • Like
Reactions: noctis90210

Grim Ripper

Well-Known Member
Member
Joined
Jan 25, 2016
Messages
256
Trophies
0
XP
325
Country
Greece
I wonder if people might be able to check out their save file, at the first 16 bytes or so, and then 'like' this post if they're:

09 00 00 00 40 00 00 00 ff 58 00 00 3f 59 00 00

I'd particularly be interested if someone has an old save from before the last update still around and could check that one as well.
Thank you!

EDIT: I pushed an alpha release that includes @supercarotte's updates for the new Pokémon and bulk edits with a few minor tweaks.

Please let me know if anything breaks, and make sure to backup before using it. It didn't look like it did anything horrible to my save but I really didn't try much. So, yes. Very alpha. Much bugs probably.

I have 5 save files starting January 2016 and all of them have the exact same bytes at the beggining.
 

nic0lette

Well-Known Member
Newcomer
Joined
Feb 5, 2016
Messages
70
Trophies
0
Age
40
XP
100
Country
United States
Thanks for the feedback. =)

Giving more lollipops shouldn't matter, I don't think, since I put in code that caps what the max level is. What would be neat is to discover (which would be in the data files): which Pokémon are actually included (ie: not dex #999) and how many of the various lollipops/treats they can have. (Since it would be kind of neat to be able to click "Max Level" and have it also provide the right number of lollipops)

I might just try to put in a hack for the experience thing soon. I just need to grab the proper attack values for everyone from some website.

Or if someone wants to help with that it would be neat to add some information to species.txt and mons.txt -- specifically it would be neat to add the base attack power to each species in species.txt (so the line would go from just "Pikachu" to "Pikachu, 50") and then, in mons.txt, add the Pokédex number of the form that it is, and "mega" if it's a Mega evolution.

So Mega Mawile would be: "Mega Mawile, 111, mega" but Angry Pikachu would just be "Angry Pikachu, 25"

The changes to species.txt is much more interesting since then I'll actually be able to add in the experience calculations and fix the oddness surrounding changing a Pokémon's level. The changes to mons.txt will just make the code a bit nicer. =)

Sorry, I just keep asking people for contributions ^^;

EDIT: I guess different forms of Pokémon can have different power? I didn't realize that ._. Are most the same (sorry, I'm not very far along, really) or do most vary? If most are the same (what I saw from the Pikachu set) then leaving them in species.txt might be fine and then just add an attack value in mons.txt for the few different ones? (I was looking at Rotom when I saw this - most are 50 attack but one is 60?)

EDIT 2: Actually, I wonder if there's only the one that's been released?

Oh! And adding the number of lollipops a Pokémon can have would be cool! (For the max level thing and for the ability to feed them in the editor. I guess any of those things... raise max level, mega speedup, etc...) Still, attack power is the one I think would be most interesting to have in there until it can be discovered in the data files.

EDIT 3: Oh! And I got it to compile & run on my Mac! \^o^/ (My Mac is just so much nicer to develop on ._.)
 
Last edited by nic0lette,

supercarotte

Well-Known Member
Member
Joined
May 21, 2015
Messages
691
Trophies
0
Age
30
XP
948
Country
France
Thanks for the feedback. =)

Giving more lollipops shouldn't matter, I don't think, since I put in code that caps what the max level is. What would be neat is to discover (which would be in the data files): which Pokémon are actually included (ie: not dex #999) and how many of the various lollipops/treats they can have. (Since it would be kind of neat to be able to click "Max Level" and have it also provide the right number of lollipops)

I might just try to put in a hack for the experience thing soon. I just need to grab the proper attack values for everyone from some website.

Or if someone wants to help with that it would be neat to add some information to species.txt and mons.txt -- specifically it would be neat to add the base attack power to each species in species.txt (so the line would go from just "Pikachu" to "Pikachu, 50") and then, in mons.txt, add the Pokédex number of the form that it is, and "mega" if it's a Mega evolution.

So Mega Mawile would be: "Mega Mawile, 111, mega" but Angry Pikachu would just be "Angry Pikachu, 25"

The changes to species.txt is much more interesting since then I'll actually be able to add in the experience calculations and fix the oddness surrounding changing a Pokémon's level. The changes to mons.txt will just make the code a bit nicer. =)

Sorry, I just keep asking people for contributions ^^;

EDIT: I guess different forms of Pokémon can have different power? I didn't realize that ._. Are most the same (sorry, I'm not very far along, really) or do most vary? If most are the same (what I saw from the Pikachu set) then leaving them in species.txt might be fine and then just add an attack value in mons.txt for the few different ones? (I was looking at Rotom when I saw this - most are 50 attack but one is 60?)

EDIT 2: Actually, I wonder if there's only the one that's been released?

Oh! And adding the number of lollipops a Pokémon can have would be cool! (For the max level thing and for the ability to feed them in the editor. I guess any of those things... raise max level, mega speedup, etc...) Still, attack power is the one I think would be most interesting to have in there until it can be discovered in the data files.

EDIT 3: Oh! And I got it to compile & run on my Mac! \^o^/ (My Mac is just so much nicer to develop on ._.)

Okay, first 1.3.6 didn't seem to change anything to the game files because the cxi that braindump dumped has the same md5 hash. This is strange, because Zygarde and Totemic Landorus stages that appeared must come from somewhere. I guess it has to do with ExtData, so I'll lay an eye on it.

If you want to know which is the game index for every pokemon, it's stored as the first 6 bytes of each sequence in the PokemonData.bin file. Everything that starts with "E7 03" will be number 999 in game, but that's not enough to know if it's fully implemented because some pokemons like Turtwig's and Empoleon's families have an in-game number but are still of normal-type.
I also found that PokemonData.bin stores the entry index in species.txt for each pokemon at 0x06-07 (to read with >> 32 and &3FF). Bulbasaur is 0 & Zygarde is 717, no matter which form. Maybe we could read from there instead of hacking it into monst.txt ?
Finally, I gave up on finding the attack values in PokemonData.bin, as there don't seem to be any offset that's consistent with this statement. Idk where it is yet, but it's probably in another file.

Yeah, forms can have different attack stats (like neutral motisma is 60 when the other are 50), so we should probably put them in mons.txt instead. Pokemon that haven't been released have a base power of 30 and behave as such in terms of xp per level, so it'd probably be a good idea to leave a blank spot for it on unreleased pokemons (like"Mega Metagross,376,,mega").

So nowI'm off to find where the attack stat, number of lollipops usable & number of mega candies usable are stored.:mthr:

EDIT: Oh yeah, also found that file n°11 in the "MESSAGE_XX" folders contains the names of pokemons, forms & stones for that language. Maybe it could be used later to make translations.
 
Last edited by supercarotte,

Sakito

New Member
Newbie
Joined
Apr 13, 2016
Messages
4
Trophies
0
Age
21
XP
63
Country
France
Hello , First : Thanks for updating the shuffle save editor !

I have downloaded on Nicolette's Github the PSSE-Master but , i don't found the shuffle save editor .exe

help please!
 
Last edited by Sakito,

supercarotte

Well-Known Member
Member
Joined
May 21, 2015
Messages
691
Trophies
0
Age
30
XP
948
Country
France
Hello , First : Thanks for updating the shuffle save editor !

I have downloaded on Nicolette's Github the PSSE-Master but , i don't found the shuffle save editor .exe

help please!

It's an alpha so there is no .exe yet. What you downloaded is the source code, you can open the .sln file in Visual Studio to build a .exe yourself.

Else, use the 1.1 release. It's not up-to-date but more stable.
 
  • Like
Reactions: Sakito

supercarotte

Well-Known Member
Member
Joined
May 21, 2015
Messages
691
Trophies
0
Age
30
XP
948
Country
France
where can I find the 1.1 ?

https://github.com/nic0lette/PSSE/releases
It's under the 1.2 release, named "PSSE.v1.1.zip"

PS : @nic0lette I realised I already had found where the data for mega speedups is stored. Now I just need to figure where the limit for each mega is stored in the game's files.

Also, suloku's and KaleoOmega's work about mega-speedups was correct. The number of speedups given to each of the 48 mega pokemons is stored at offsets 0x2D5B-2D85, shifted by 3 bits to the left (so the bloc actually includes only the last 3 bits of 0x2D85 and doesn't include the last 3 bits of0x2D5B). That means you need to read the block backwards then divide it by 8 (move it 3 bits to the right) to read it.

Mega-pokemons are sorted in their pokédex order (not in-game order !) with its number of speedups coded onto a 7-bit digit, probably because 7 bits are needed to go to 99 (it actually goes up to 127).
This explains the strange overflows in suloku's and KaleoOmega's work : it actually overflows to 127, but the number displayed is truncated to have as many digits as the max. number of speedups for this pokemon, so Kangashkan displays 7/8 & rayquaza displays 27/20.

For those of you who would want to max speedups manually, you can paste to 0x2D5B-2D85 either :
"18 14 06 84 40 20 20 08 20 02 81 43 A1 70 38 04 0C 81 C0 60 30 28 20 0E 01 C3 41 11 30 20 06 86 40 80 51 A0 20 14 84 41 60 60 00" -> gives you the max. amount of speedups for every mega-pokémon (including unreleased ones)
or
"18 14 06 04 00 00 20 08 20 00 80 43 A1 70 38 00 0C 00 C0 60 30 28 20 0E 00 C3 41 01 30 20 06 06 00 80 51 A0 20 14 84 01 60 60 00" -> gives you max. amount of speedups for currently released mega-pokemons (as of 1.3.4) only.
(or just overwrite all the block with "FF" offsets if you want overflow to 127 but I don't know if it enhances the mega-evolution gauge further than the legit max.)

If you want the order of mega-pokemons, go there (from top to bottom)
 
Last edited by supercarotte,
  • Like
Reactions: jonfox_sv

nic0lette

Well-Known Member
Newcomer
Joined
Feb 5, 2016
Messages
70
Trophies
0
Age
40
XP
100
Country
United States
Okay, first 1.3.6 didn't seem to change anything to the game files because the cxi that braindump dumped has the same md5 hash. This is strange, because Zygarde and Totemic Landorus stages that appeared must come from somewhere. I guess it has to do with ExtData, so I'll lay an eye on it.

*nod**nod* That makes sense given that we download this via checkin. (Don't we? o.o)

If you want to know which is the game index for every pokemon, it's stored as the first 6 bytes of each sequence in the PokemonData.bin file. Everything that starts with "E7 03" will be number 999 in game, but that's not enough to know if it's fully implemented because some pokemons like Turtwig's and Empoleon's families have an in-game number but are still of normal-type.

Okay, but it's still a start. I feel odd seeing all of the various forms of Pikachu in there that really shouldn't be released yet.

I also found that PokemonData.bin stores the entry index in species.txt for each pokemon at 0x06-07 (to read with >> 32 and &3FF). Bulbasaur is 0 & Zygarde is 717, no matter which form. Maybe we could read from there instead of hacking it into monst.txt ?

Neat! That would clean up the odd business around the adjectives a bit, I think?

Finally, I gave up on finding the attack values in PokemonData.bin, as there don't seem to be any offset that's consistent with this statement. Idk where it is yet, but it's probably in another file.

Perhaps. =/

Yeah, forms can have different attack stats (like neutral motisma is 60 when the other are 50), so we should probably put them in mons.txt instead. Pokemon that haven't been released have a base power of 30 and behave as such in terms of xp per level, so it'd probably be a good idea to leave a blank spot for it on unreleased pokemons (like"Mega Metagross,376,,mega").

Yeah. Ideally I'd like to remove the unreleased Pokémon from the UI and the bulk changes. (ie: "All Caught" should only catch all released Pokémon, I think?)

Have the other forms of Rotom been released?

So nowI'm off to find where the attack stat, number of lollipops usable & number of mega candies usable are stored.:mthr:
:grog:

EDIT: Oh yeah, also found that file n°11 in the "MESSAGE_XX" folders contains the names of pokemons, forms & stones for that language. Maybe it could be used later to make translations.

Awesome =D And, actually, if the strings there include the form names that could also help with the whole species/mons thing. =D

Thank you very much! \^o^/
 
  • Like
Reactions: supercarotte

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • BigOnYa
  • BakerMan
    I rather enjoy a life of taking it easy. I haven't reached that life yet though.
    BigOnYa @ BigOnYa: We had our grandkids over yesterday and I got a small above ground swimming pool I filled for...