ROM Hack PSSE - Pokemon Shuffle Save Editor

  • Thread starter Thread starter SciresM
  • Start date Start date
  • Views Views 374,561
  • Replies Replies 1,267
  • Likes Likes 40
Okay, so I should have found how the savefile handles exp values. The offset starts at 0x3421 and potentially goes up to 0x4140 (0x4141 is where scores for each stages are stored), but right now I think it's zygarde that comes last, at offset 0x359B.

Woot! Great job! =D

I'll do my best to update this by the end of the weekend and, if I can, make it so it just automagically fixes experience values that are incorrect (ie: if a pokemon has more experience than it needs for the level it's at it leaves it, otherwise it sets the experience to the base amount for that level)

At least that's my intention. >_<
 
Hello, you could also get the sprites

Someone else already extracted them and shared them on Reddit.

@SciresM -- I downloaded and ran your tool (Pokemon-Shuffle-Unpacker) on the latest data, but there were many files it said, "Found unknown file at index blah in blah. Please contact SciresM." (And then it proceeded to throw an exception on the "Zip.ExtractAll(OutputDirectory);" line =/

I put a try/catch around that to see what it would end up creating, and it did spit out a lot of (all of?) the data, but a few things came up in addition to the above.

First, all the assets came out as .bch files, which is likely expected, but I don't know how/couldn't find a tool to convert them to .png files. (I tried Ohana3DS but it just displays an empty 3D model, and it isn't obvious how/if it can do this anyway)

Then there's the files "mons.txt" and "species.txt" -- I'm not sure how they were created and so I wasn't sure how to update them (since I'm sure the names of the Pokémon aren't in the .bin files)
 
Someone else already extracted them and shared them on Reddit.

@SciresM -- I downloaded and ran your tool (Pokemon-Shuffle-Unpacker) on the latest data, but there were many files it said, "Found unknown file at index blah in blah. Please contact SciresM." (And then it proceeded to throw an exception on the "Zip.ExtractAll(OutputDirectory);" line =/

I put a try/catch around that to see what it would end up creating, and it did spit out a lot of (all of?) the data, but a few things came up in addition to the above.

First, all the assets came out as .bch files, which is likely expected, but I don't know how/couldn't find a tool to convert them to .png files. (I tried Ohana3DS but it just displays an empty 3D model, and it isn't obvious how/if it can do this anyway)

Then there's the files "mons.txt" and "species.txt" -- I'm not sure how they were created and so I wasn't sure how to update them (since I'm sure the names of the Pokémon aren't in the .bin files)

Gave it a try too and I got the same exception.
PSU prints :
Extracting 0A040000 (94 files)...
Found unknown file at index 08 in 0A040000. Please contact SciresM.
Zip 08 will not be deleted for debugging purposes.
...

The exception I get at Zip.ExtractAll(OutputDirectory); is "Unauthorized characters in access path", and visual studio shows me the variable OutputDirectory, which is "D:\\rom\\Item Graphics (0A040000)\\" in my case, in red.

It seems to be a problem with the "Rename Known fils" option, because when I disable it everything works properly :
Extracting 0A040000 (94 files)...Complete!
Extracting 1F900000 (23 files)...Complete!
Extracting 21040000 (7 files)...Complete!
Extracting 26740000 (14 files)...Complete!
Unable to find a name for 29A80000. Please contact SciresM.
Extracting 29A80000 (1 files)...Complete!
Extracting 2D700000 (97 files)...Complete!
Extracting 4E540000 (2 files)...Complete!
Extracting 58F80000 (3 files)...Complete!
Extracting 66140000 (1 files)...Complete!
Extracting 69680000 (152 files)...Complete!
Extracting 72940000 (1 files)...Complete!
Extracting 8A640000 (1 files)...Complete!
Extracting 8BA80000 (10 files)...Complete!
Extracting 8F280000 (5 files)...Complete!
Extracting 91280000 (996 files)...Complete!
Extracting 9D3C0000 (1 files)...Complete!
Extracting 9EB40000 (85 files)...Complete!
Extracting A4700000 (23 files)...Complete!
Extracting A6540000 (14 files)...Complete!
Extracting A8A40000 (2 files)...Complete!
Extracting B6680000 (68 files)...Complete!
Unable to find a name for BF9C0000. Please contact SciresM.
Extracting BF9C0000 (1 files)...Complete!
Extracting C6CC0000 (1062 files)...Complete!
Extracting D6B80000 (10 files)...Complete!
Extracting D9AC0000 (44 files)...Complete!
Extracting DC440000 (1 files)...Complete!
Extracting E5500000 (1 files)...Complete!
Extracting E5BC0000 (132 files)...Complete!
Extracting ED8C0000 (3 files)...Complete!
Extracting EFDC0000 (1 files)...Complete!
Extracting F054000A (24 files)...Complete!
Extracting F0540012 (24 files)...Complete!
Extracting F0540022 (24 files)...Complete!
Extracting F0540042 (24 files)...Complete!
Extracting F0540082 (24 files)...Complete!
Extracting F0540102 (24 files)...Complete!
Extracting F0540202 (24 files)...Complete!
Extracting F0550002 (24 files)...Complete!
Extracting F0560002 (24 files)...Complete!
Extracting F3FC0000 (3 files)...Complete!
Extracting FA940000 (2 files)...Complete!
(Seems like there are a few new folders that aren't in your list)

The only problem is that the files I get aren't renamed (but folders are, except for the 2 I highlighted) so it's a bit hard to know what to do with them^^ I can PM you or nic0lette the archive I got if you want (not sure posting it publicly is a good idea).

EDIT: tried extracting each file one-by-one with "rename known files" option active, I get errors for a lot of them :
FOLDER : INDEX
0A040000 : 08
1F900000 : 15
2D700000 : 37

4E540000 is ok
8A640000 is ok
8BA80000 : 06
82F80000 is ok
9D3C0000 is ok
9EB40000 : 81
29A80000 : 0

58F80000 is ok
21040000 is ok
26740000 is ok
66140000 is ok
69680000 : 004
72940000 is ok
91280000 : 854
A8A40000 is ok
A4700000 : 04
A6540000 is ok
B6680000 : 02
BF9C0000 : 0
C6CC0000 : 866

D6B80000 is ok
D9AC0000 : 22
DC440000 is ok
E5BC0000 is ok
E5500000 is ok
ED8C0000 is ok
F3FC0000 is ok
F054000A : 05
F0540012 : 05
F0540022 : 05
F0540042 : 05
F0540082 : 05
F0540102 : 05
F0540202 : 05
F0550002 : 05
F0560002 : 05

FA940000 is ok

It's likely that there are other problematic files, but since PSU breaks after these I don't know which ones. By checking the modification date of the files, I realised they were all recent (2016 or late 2015) so I guess there is problem with files that PSU doesn't know what they are because they were added after you created your database.

EDIT 2 :
I'm trying to figure out what is inside the "new" files.
05 = mission cards text
06 = options/stats menu (the one where you can see play time)
07 = ???
08 = pop-ups (when you receive items)
09 = "pokédex menu" (where you choose your party pokemons, it contains the name & description of every ability)
10 = ???
11 = listing of pokemons, mega-stones & forms
12 = trainer texts
13 = types
14 = competitive stages texts
15 = after-battle texts (also, a lot of spoilers about Skill+ items)
16 = diamond store texts
17 = Options menu texts (where you manage Streetpass/Spotpass)
18 = item store texts
19 = main screen texts
20 = Streetpass menu
21 = User code menu
22 = Pokathlon texts
23 = tutorial texts
There's only 1 file (0), seems like it's the Mission cards menu "configuration file"
0866 = bound hoopa
0867 = unbound hoopa
0868 = volcanion
0869-0916 = mega-pokemons sprites (pink outlines)
0917-0964 = mega-pokemon sprites
0965-0967 = winking bulbasaur, charmander & squirtle
0968-981 = angry, winking, sleepy, annoyed, nasty, surprised, in love, crying, depressed, happy, drowsy, blinking, magician, Xmas pikachu
0982-0986 = winking raichu, clefairy, clefable, jigglypuff & his evolution
0987 = tongue gengar
0988 = winking chansey
0989 = gold magikarp
0990 = red gyarados
0991-1001 = winking chikorita, fire starter gen2, totodile, togetic, marill, azumarill, hoppip, skiploom, jumpluff, snubbull, granbull
1002 = Xmas delibird
1003-1008 = winking blissey, treecko, firestartergen3, mudkip, shroomish, delcatty
1009 = cape sableye
1010-1014 = winking plusle, minun, morpheo, snorunt, glalie
1015 = shiny rayquaza
1016-1037 = winking gen4 starters (x3), roserade, pachirisu, cherubi, cherrim, blizzi (happy), togekiss, phione, manaphy, gen5 starters (x3), audino, cotonnee, whimsicott, vanillite (happy), cubchoo (happy), gen 6 starters (x3)
1038 = sachanobi
1039-1045 = winking flabébé, floette, aromatisse, spritzee, slurpuff, dedenne, carbink
1046-1047 = happy pumpkaboo & gourgeist
1048 = 10% zygarde
1049 = 100% zygarde
1050-1055 = mega gengar, shiny gyarados, sableye, glalie, shiny rayquaza, audino (pink outline, probably associated with the new forms of these pokemons)
1056-1061 = like above but without pink outline
0854 = bound hoopa
0855 = unbound hoopa
0856 = volcanion
0857-0904 = mega-pokemons sprites
0905-0907 = winking bulbasaur, charmander & squirtle
0908-0921 = angry, winking, sleepy, annoyed, nasty, surprised, in love, crying, depressed, happy, drowsy, blinking, magician, Xmas pikachu
0922-0926 = winking raichu, clefairy, clefable, jigglypuff & his evolution
0927 = tongue gengar
0928 = winking chansey
0929 = gold magikarp
0930 = red gyarados
0931-0941 = winking chikorita, fire starter gen2, totodile, togetic, marill, azumarill, hoppip, skiploom, jumpluff, snubbull, granbull
0942 = Xmas delibird
0943-0948 = winking blissey, treecko, firestartergen3, mudkip, shroomish, delcatty
0949 = cape sableye
0950-0954 = winking plusle, minun, morpheo, snorunt, glalie
0955 = shiny rayquaza
0956-0977 = winking gen4 starters (x3), roserade, pachirisu, cherubi, cherrim, blizzi (happy), togekiss, phione, manaphy, gen5 starters (x3), audino, cotonnee, whimsicott, vanillite (happy), cubchoo (happy), gen 6 starters (x3)
0978 = sachanobi
0979-0985 = winking flabébé, floette, aromatisse, spritzee, slurpuff, dedenne, carbink
0986-0987 = happy pumpkaboo & gourgeist
0988 = 10% zygarde
0989 = 100% zygarde
0990-0995 = mega gengar, shiny gyarados, sableye, glalie, shiny rayquaza, audino (probably associated with the new forms of these pokemons)
22 = match_fast sprite (for the new fast-link type of battle mega-sceptile uses)
23 = stars & sparkles
24 = match_mega_res
25 = match_skill (flash & sparkles)
26 = match_skill (sword sprite)
27 = match_skill (shield sprite)
28 = match_skill (mega sprite)
29 = mega_change (mega-evolution symbol)
30 = mega_env (the rainbow things aroung the grid when mega-evolution is activated)
31 = mega_evolve (mega symbol w/sparkles & light effects)
32 = mega_evolve_bg
33 = reset_puzzle (???)
34 = runaway (smoke effect)
35 = shadow_ennemy
36-41 = st_paralyse/burnt/fear/sleep/freeze/poison (status effects)
42 = env_black (???)
43 = unsupported file format
 
Last edited by supercarotte,
So the good news is that I have all the calculations for experience points (reading a Pokémon's experience from the file as well as being able to go back and forth between level and experience points).

I also updated the bulk edit box to give 99 of each of the new items, to match with how it used to work.

And, finally, I did update the data with the values I extracted and nothing blew up.

Okay, so the bad news is that I can't figure out a Pokémon's attack (or can't figure out how to from the data, at least), so I can't actually figure out how much experience one needs to be at a particular level.

I'm also not sure if any of the new data is being read because I don't know the order for the new Pokémon, so I can't add them to the "mons.txt" list (which is where, I think, "Angry Pikachu" and "Winking Bulbasaur" would go -- the strings, I mean)

And then there are the graphics. I downloaded a tool to try and convert bch to png files. And then I installed Python to try to get it to work. And then I installed Cygwin to try and get it to work. And then I tried to hunt down the source for the utility so I could compile it on my OS X box, but everything failed.

So right now I basically have a bit of new code and a shiny progress bar waiting to be filled in to show the Pokémon's experience, but no pictures and no data =(

Sorry. Programming things I can do, but I suck at trying to reverse engineer stuff =(

EDIT: Okay, so I hacked up Ohana and added a method to bulk convert .bch files to .png files. Surprise! The files that the export tool doesn't know are the new Pokemon.

Anyone have any idea for what numbers they are (to match the dex-like-ish number list in the app)?

I also discovered that there are ~130 main stages missing, along with quite a few expert and specials, even after updating the files, so I'm not sure what to do about that =/
 

Attachments

Last edited by nic0lette,
So the good news is that I have all the calculations for experience points (reading a Pokémon's experience from the file as well as being able to go back and forth between level and experience points).

I also updated the bulk edit box to give 99 of each of the new items, to match with how it used to work.

And, finally, I did update the data with the values I extracted and nothing blew up.

Okay, so the bad news is that I can't figure out a Pokémon's attack (or can't figure out how to from the data, at least), so I can't actually figure out how much experience one needs to be at a particular level.

I'm also not sure if any of the new data is being read because I don't know the order for the new Pokémon, so I can't add them to the "mons.txt" list (which is where, I think, "Angry Pikachu" and "Winking Bulbasaur" would go -- the strings, I mean)

And then there are the graphics. I downloaded a tool to try and convert bch to png files. And then I installed Python to try to get it to work. And then I installed Cygwin to try and get it to work. And then I tried to hunt down the source for the utility so I could compile it on my OS X box, but everything failed.

So right now I basically have a bit of new code and a shiny progress bar waiting to be filled in to show the Pokémon's experience, but no pictures and no data =(

Sorry. Programming things I can do, but I suck at trying to reverse engineer stuff =(

EDIT: Okay, so I hacked up Ohana and added a method to bulk convert .bch files to .png files. Surprise! The files that the export tool doesn't know are the new Pokemon.

Anyone have any idea for what numbers they are (to match the dex-like-ish number list in the app)?

I also discovered that there are ~130 main stages missing, along with quite a few expert and specials, even after updating the files, so I'm not sure what to do about that =/

Nice !! PSSE's updating is in good progession :yay:

I attached a mons.txt I made, could you test it and tell me if it seems legit to you ? I updated the mons.txt from your github with the order of the new sprites I found in C6CC0000, just in case it's that simple.

Also, I believe Attack stats are listed in a separate file. For that, check your PMs. ;)

Finally, not related but while screwing around I accidentally overwrote team data with FFs, which gave me a quite funny result. If anyone can translate the japanese text from attached pic, please do.
 

Attachments

  • Like
Reactions: Madridi
That's not the latest though is it? Last changes 7 days ago. I don't think she pushed the latest code to github yet (which is the right call, since it's still in testing phase)

You're probably right, yet that means taht's the latest public version^^ I guess nic0lette will push the code once the new features work correctly.
 
  • Like
Reactions: Madridi
I updated the mons.txt from your github with the order of the new sprites I found in C6CC0000, just in case it's that simple.

Looks good, but it didn't change anything =( There's this complicated (to me) interplay between all the data files that I don't quite get =/

Also, I believe Attack stats are listed in a separate file. For that, check your PMs. ;)

Thanks! Sadly I think this file (PokemonAttack.bin) is the attacks each of the Pokémon can perform (power of 4, burn, stabilize, etc...) rather than the attack power of each. (There aren't many values in there, and while some look like they could be attack values, there are others that are like, '8' which doesn't make sense.)

I tried looking at PokemonData.bin again, dumping the info for each of the gen 1 starters (since they're all "Power of 4" and 40 attack) and then comparing them with Espurr (40 attack but "Opportunist") -- no luck =(

I wonder how much time it would take to just create our own representation of this data... We've basically spent more than a week pulling the data files out and trying to analyze them thus far, and I know I'm at least using (at least partially) various websites to verify the numbers I'm seeing.

Thoughts?

Finally, not related but while screwing around I accidentally overwrote team data with FFs, which gave me a quite funny result. If anyone can translate the japanese text from attached pic, please do.

It says, "Dummy Pokémon" XD

That's not the latest though is it? Last changes 7 days ago. I don't think she pushed the latest code to github yet (which is the right call, since it's still in testing phase)

Yeah, sorry. =( I've put a bunch of stuff in that hasn't been tested *at all*. I can push it and you can grab that, but I don't want to build and publish something that's not at least a little "done".
 
Last edited by nic0lette,
  • Like
Reactions: Madridi
Yeah, sorry. =( I've put a bunch of stuff in that hasn't been tested *at all*. I can push it and you can grab that, but I don't want to build and publish something that's not at least a little "done".
As I said, it was the right call :) .. Better have it controlled over here first before pushing anything.

I'm glad to see work on this being done. Hopefully I'll be of more help once I'm back from my trip :)
 
I came up with a (what I think at least) is a cute little way to grab the "dex like" order of the new Pokémon.

I went and I edited my save to have "caught" those I'm interested in, and then I set their level to the index they're in. (So here you can see that Angry Pikachu is level 6 which means that he's at dex like index 786.

Unfortunately that means that I have no idea how the "mons.txt" file works at all
(╯°□°)╯︵ ┻━┻

Well, actually I'm sure it has something to do with the index of mega evolutions (bool isMega = i > 782 && i < 831)

Blah.
 

Attachments

  • IMG_20160410_161716.jpg
    IMG_20160410_161716.jpg
    414.4 KB · Views: 410
I came up with a (what I think at least) is a cute little way to grab the "dex like" order of the new Pokémon.

I went and I edited my save to have "caught" those I'm interested in, and then I set their level to the index they're in. (So here you can see that Angry Pikachu is level 6 which means that he's at dex like index 786.

Unfortunately that means that I have no idea how the "mons.txt" file works at all
(╯°□°)╯︵ ┻━┻

Well, actually I'm sure it has something to do with the index of mega evolutions (bool isMega = i > 782 && i < 831)

Blah.

PGJjaTk.png

I probably have fixed mons.txt as well as the other ressource files, I just need to learn how to contribute it to your github. :rofl2:

I kept most things intact, just updated the reading offsets & .resx file, but I had to use the source from your 1.1 release (the latest one wasn't loading my saves for some reason). Also, keep in mind that I'm a terrible programmer (that's why I kept changes to a minimum) so I'm sorry if I broke something. :ohnoes:
 
  • Like
Reactions: Madridi
Thank you all for your efforts in making an updated version of PSSE.

So is it a new version or you just updated the files like SciresM said?
 
  • Like
Reactions: pbanj
Thank you all for your efforts in making an updated version of PSSE.

So is it a new version or you just updated the files like SciresM said?

I changed something like 4-5 lines of codes so that PSSE is able to read the new resource files, I wouldn't call this a new version yet^^ Wait a bit for the newer functions, if what I did is correct we'll start working on it.

EDIT: yeah, I got the pull request working and it only took me 1 hour ! Now I feel like a real dev :hrth:
 
Last edited by supercarotte,
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?
 

Site & Scene News

Popular threads in this forum