Update: problem solved, info a little further down!
Hi all,
I'm a Linux dev by profession and a lifelong Pokemon fan
I was getting irritated trying to receive a certain Pokemon from a popular GTS distribution so I decided to run an experiment... I used the awesome GTS & pkm struct wikis hosted here (incredible job by the community!), modified ir-gts-bw and captured & studied the headers from a GTS transfer. After more experimentation I figured if I captured the output from the following, I should be able to get a .pkm file data back from the server:
$ curl 'http://<distro_server>/worldexchange/result.asp?'
Well, I do get what looks some .pkm data, but it's 336 bytes. I dd'd the first 236 bytes of the response to a file, and this file is indeed a valid .pkm file - it opens in PokeGen and everything seems cool with it.
So I scripted downloading all unique .pkm from this distro server by this method and have 60+ files to deal with...
At this point, I can save one of these files in PokeGen as a 236-byte non-encrypted pkm file (which is actually only 220 bytes for B/W) and this can then be sent to my game via ir-gts-bw.
I tried trimming the last 16 bytes from my 236 byte files to make them 220 bytes, but these aren't valid .pkm files. I could open them all up in PokeGen and save them, but would rather not spend the time doing so if I don't have to.
TL;DR - Is there a script to convert a GenV 236-byte .pkm into a 220-byte file? I know I can do it in PokeGen but I'm a script kinda guy.
I'd be happy to provide more info if someone can help.
Thanks!