Search the Community
Showing results for tags 'structures'.
-
6th and 7th Generation Wonder Card Map Mystery Gift Data WCxFULL Offset WCx Offset Gen 6 Gen 7 0x00-0x03 - Bit 0 - Y Bit 1 - X Bit 2 - AS Bit 3 - OR Bit 0 - S Bit 1 - M Bit 2 - US Bit 3 - UM 0x04-0x01FD - Redemption Text 0x01FE - 0x01 - Green Background 0x01 - Halo Animation 0x01FF - Allowed Languages 0x00 - Any Language Otherwise Language ID 0x200 - Once Per Week Bit 0 - Multiple WCs 0x201 - Unused? SubID 0x0202-0x0203 - Checksum Checksum is a CCITT-16. (CRC16-CCITT) It is computed using all the 0x310 bytes. The checksum location have to be filled with zeroes. (dates are included in calculation) 0x0204 - Unused? Set Count 0x205 - Always 0x46 Rarity Weight 0x206-0x207 - Always 0x4646 0x208-0x209 0x00-0x01 Card ID 0x20A-0x253 0x02-0x4B Card Title 0x254-0x257 0x4C-0x4F Card Reception Date YYYYMMDD Card Redemption Date YYMMDD 0x258 0x50 Card Location 0x259 0x51 Card Type 0x0 - Pokemon 0x1 - Item Card Type 0x0 - Pokemon 0x1 - Item 0x3 - BP 0x25A 0x52 Statuses Bit 0 - Only Once Bit 1 - Used Statuses Bit 0 - Only Once Bit 1 - Used Bit 2 - Once per Day 0x25B 0x53 Animation Background Color 0x0 - Blue 0x1 - Green (0x53 offset only) Card Background Color 0x0 - Blue 0x1- Purple 0x2 - Gold 0x25C-0x26F 0x54-0x67 Unknown/Unused 0x26E - Always 0xFF Pokémon Cards WCxFULL Offset WCx Offset Gen 6 Gen 7 0x270-0x271 0x68-0x69 Trainer ID 0x272-0x273 0x6A-0x6B Secret ID 0x274 0x6C Game of Origin 0x0 - Receiver's Game 0x274-0x277 0x6D-0x70 Unused 0x278-0x27B 0x71-0x73 Encryption Constant 0x0 - Randomly Generated 0x27C-0x27D 0x74-0x75 Ribbons See Ribbon Data Below 0x27E-0x27F 0x76-0x77 PokéBall Caught In 0x280-0x281 0x78-0x79 Held Item 0x282-0x283 0x7A-0x7B Move #1 0x284-0x285 0x7C-0x7D Move #2 0x286-0x287 0x7E-0x7F Move #3 0x288-0x289 0x80-0x81 Move #4 0x28A-0x28B 0x82-0x83 PokéDex Number 0x28C 0x84 Form Index 0x28D 0x85 Language 0x0 - Receiver's Language Otherwise Language ID 0x28E-0x2A7 0x86-0x9F Pokémon Nickname No terminator if no nickname 0x2A8 0xA0 Nature 0xFF - Random 0x2A9 0xA1 Pokémon Gender 0x0 - Male 0x1 - Female 0x2 - Genderless 0x3 - Random 0x2AA 0xA2 Pokémon Ability 0x0 - Ability 1 0x1 - Ability 2 0x2 - Hidden Ability 0x3 - Ability Random (No HA) 0x4 - Ability Random (All) 0x2AB 0xA3 Personality ID Generation Method 0x0 - Use specified PID 0x1 - Random can be shiny PID 0x2 - Random always shiny PID 0x3 - Random never shiny PID 0x2AC-0x2AD 0xA4-0xA5 Egg Met Location 0x2AE-0x2AF 0xA6-0xA7 Met Location 0x2B0 0xA8 Met Level 0x2B1-0x2B6 0xA9-0xAE Contest Stats Last byte is Sheen 0x2B7-0x2BC 0xAF-0xB4 IVs 0xFFFFFFFF - Random 0xFFFFFFFE - 3 31s 0xFFFFFFFD - 2 31s 0x2BD 0xB5 Trainer Gender 0x0 - Male 0x1 - Female 0x3 - Recipient's Gender 0x2BE-0x2D7 0xB6-0xCF Trainer Name All 00's - Recipient's Name 0x2D8 0xD0 Current Level 0x2D9 0xD1 Egg Flag 0x1 - Is Egg 0x2DA-0x2DB 0xD2-0xD3 Unused Bundled Item ID 0x2DC-0x2DF 0xD4-0xD7 Personality ID Almost Always 0xEE6B2802 Sometimes 0x00000000 0x2E0-0x2E1 0xD8-0xD9 Relearn Move 1 0x2E2-0x2E3 0xDA-0xDB Relearn Move 2 0x2E4-0x2E5 0xDC-0xDD Relearn Move 3 0x2E6-0x2E7 0xDE-0xDF Relearn Move 4 0x2E8-0x2E9 0xE0-0xE1 Trainer Memory Intensity Unused 0x2EA-0x2EB 0xE2-0xE3 Trainer Memory Line Unused 0x2EC-0x2ED 0xE4-0xE5 Trainer Memory TextVar 0xE5-0xEA: EVs 0x2EF-0x2F0 0xE6-0xE7 Trainer Memory Feeling 0x2F1-0x2F3 0xE8-0xEA Unused 0x2F4-0x30F 0xEB-0x107 Unused Unused Item Cards WCxFULL Offset WCx Offset Gen 6 Gen 7 0x270-0x271 0x68-0x69 Item ID Item 1 ID 0x272-0x273 0x6A-0x6B Unused Item 1 Quantity 0x274-0x275 0x6C-0x6D Unused Item 2 ID 0x276-0x277 0x6E-0x6F Unused Item 2 Quantity 0x278-0x279 0x70-0x71 Item Quantity Item 3 ID 0x27A-0x27B 0x72-0x73 Unused Item 3 Quantity 0x27C-0x27D 0x74-0x75 Unused Item 4 ID 0x27E-0x27F 0x76-0x77 Unused Item 4 Quantity 0x280-0x281 0x78-0x79 Unused Item 5 ID 0x282-0x283 0x7A-0x7B Unused Item 5 Quantity 0x284-0x285 0x7C-0x7D Unused Item 6 ID 0x286-0x287 0x7E-0x7F Unused Item 6 Quantity Ribbon Set Flag Value 0x74 0x75 0x01 Battle Champ Ribbon World Champ Ribbon 0x02 Regional Champ Ribbon Birthday Ribbon 0x04 National Champ Ribbon Special Ribbon 0x08 Country Ribbon Souvenir Ribbon 0x10 National Ribbon Wishing Ribbon 0x20 Earth Ribbon Classic Ribbon 0x40 World Ribbon Premier Ribbon 0x80 Event Ribbon Empty
- 1 comment
-
- 2
-
- structures
- technical references
-
(and 1 more)
Tagged with:
-
5th Generation Wonder Card Map Gift Data Offset Description 0x00-0x01 Trainer ID Number, Item Number, Power Type 0x02-0x03 Secret ID Number 0x04 Hometown 00 - Game Received In 01 - Hoenn(Sapphire) Values follow in standard order through 21 0x05-0x07 Unused 0x08-0x0B PID Unset = 00000000 0x0C Primary Ribbons Ribbon data available below. 0x0D Secondary Ribbons Ribbon data available below. 0x0E PokéBall 0x0F Unused 0x10-0x11 Held Item 0x12-0x13 Move ID #1 0x14-0x15 Move ID #2 0x16-0x17 Move ID #3 0x18-0x19 Move ID #4 0x1A-0x1B PokéDex Number 0x1C Unused 0x1D Language 00 for Game Received In 0x1E-0x33 Pokémon Nickname (0x32-0x33 FF FF terminated) If no nickname, all FF. 0x34 Nature FF - Unset 0x35 Pokémon Gender 00 - Male 01 - Female 02 - Random 0x36 Pokémon Ability 00 - Ability 1 01 - Ability 2 02 - Dream World Ability 03 - RND(Abil1, Abil2) 04 - RND(Abil1, Abil2, AbilDW) 0x37 Shiny Toggle 00 - Not Shiny 01 - Allow Shiny 02 - Generate Shiny PID Shows Shiny Pokemon on Card 0x38-0x39 Egg Met Location 0x3A-0x3B Met Location of Pokémon 0x3C Level - unused(?) 0x3D-0x42 Contest Stats Last byte is Sheen 0x43-0x48 IVs FFs for unset IVs 0x49 Unused 0x4A-0x59 OT Name 0x5A OT Gender 00 - Male 01 - Female 03 - Recipient's Gender 0x5B Level(random if set to 0) 0x5C Egg Flag 00 - Is Not Egg 01 - Is Egg 0x5D-0x5F Unused Card Data Offset Description 0x60-0xA9 Card Title 0xAA-0xAB Unknown 0xAC-0xAF Date Card Received 0xB0-0xB1 Card ID 0xB2 "Card From" Location 0xB3 Card Type 01 - Pokémon [Blue] 02 - (Key) Item [Pink] 03 - Power [Yellow] 0xB4 Gift Status: Used / Unused 00 - Repeatable gift 01 - Unused 03 - Used 0xB5-0xCB Unused Ribbon Sets These are the values for each ribbon byte: Flag Value 0x0C 0x0D 0x01 Country Ribbon Special Ribbon 0x02 National Ribbon Memorial Ribbon 0x04 Earth Ribbon Wish Ribbon 0x08 World Ribbon Battle Champ Ribbon 0x10 Classic Ribbon Regional Champ Ribbon 0x20 Premiere Ribbon National Champ Ribbon 0x40 Event Ribbon World Champ Ribbon 0x80 Birthday Ribbon No Ribbon(Empty) First Appearance in the Memory The Wonder Cards do appear in the active memory while the game is running, however there are certain things that are set in addition to the card data in addition to it being in two locations. The cards appear in the region of 0x0226BE30-0x0226C87F in Black, and 0x0226BE50-0x0226C89F for White. Card data is unencrypted when viewing, but encrypted at all other times. Each card is separated by 220 bytes of data. Memory Offsets of each Card when viewing, including the leading 4 bytes: Card # Offset (Black) Offset (White) 1 0x0226BE30 0x0226BE50 2 0x0226BF0C 0x0226BF2C 3 0x0226BFE8 0x0226C008 4 0x0226C0C8 0x0226C0E8 5 0x0226C1A4 0x0226C1C4 6 0x0226C280 0x0226C2A0 7 0x0226C35C 0x0226C37C 8 0x0226C438 0x0226C458 9 0x0226C514 0x0226C534 10 0x0226C5F0 0x0226C610 11 0x0226C6CC 0x0226C6EC 12 0x0226C7A8 0x0226C7C8 The card is preceded by 4 bytes, in which the first is 1 to indicate that there is a card present in that slot, being 0 when a card is not present. Meaning Data Card Present 0x00000001 No Card Present 0x00000000 The card data is then present, byte for byte for the entire 204 bytes. After the card data, there are 4 bytes (pointer?). Card # Trash Value (Black) Trash Value (White) 1 0x0226CAA4 0x0226CAC4 2 0x0226CD88 0x0226CDA8 3 0x0226D06C 0x0226D08C 4 0x0226D350 0x0226D370 5 0x0226D388 0x0226D3A8 6 0x0226D3C0 0x0226D3E0 7 0x0226D3F8 0x0226D418 8 0x0226D430 0x0226D450 9 0x0226D468 0x0226D488 10 0x0226D4A0 0x0226D4C0 11 0x0226D4D8 0x0226D4F8 12 0x02270248 0x02270268 There are then 8 unused bytes (all 00), leading up to the next card. Second Appearance in the Memory The second appearance of the unencrypted card data while viewing is varied based on the number of cards currently on the save. Since it has not been tested whether or not active/inactive gifts may change the locations, trash all used cards before using any memory codes. Cards and the surrounding data follow the first appearance's format. Kaphotics' Test Card 1 Memory Location of N Cards [Stop at (N) cards]: Black: 02277F20(1 card) +58C(2c) +590(3) +58C(4) +2E8(5) +2E4(6) +2E8(7) +2E4(8) [9-12 still testing] White: 02277F40(1 card) +58C(2c) +590(3) +58C(4) +2E8(5) +2E4(6) +2E8(7) +2E4(8) [9-12 still testing] Card 2 = Card 1 Memory + 420 Card n = Card 1 Memory + 5020 + (n-3)*4C34 || Number of cards: 13>n>2 For other DS's (with different MAC addresses) the 1st location is the same but the rest follow different additive constants between cards. The second appearances will appear in the block range of 0x02270000-0x022AFFFF.
-
- 2
-
- structures
- technical references
-
(and 2 more)
Tagged with:
-
6th Generation Pokemon Link Map Overall structure Pokémon link data is stored at block ID 0x30 of the savegame, located at offset 0x1FE00 for X/Y and 0x20DFF for OR/AS (add 0x5400 if using the referenced offsets located at Pokémon X/Y Save Structure and ORAS Save Structure respectively). Offset Description 0x00-0x? Pokémon Transfer Flags? * 0x1FF-0xC45 Pokémon Link Data 0xC46-0xDFF Unused? * Pokémon Transfer flags: this value prevents receiving the same pokémon trough Pokémon Link Multiple times. If this value is cleared, the Pokémon can be received again. This has only been used for ORAS Demo Glalie/Steeliex, both of which set this value to 0x02. Pokémon Link Data Savegame Offsets Pokémon Link Data starts in the following offsets for decrypted savegame files and is 2631 bytes long: Pokémon X/Y: 0x1FFFF Pokémon OR/AS: 0x20FFF Modifying this data requires checksum #0x30 to be updated. Also, for ramsav users (ramsav method does not require to fix checksum): ramsav.bin offset Pokémon X/Y: 0x1CF9F ramsav.bin offset Pokémon OR/AS: 0x1E05B Pokémon Link Data Map Offset Description 0x00 Pokémon Link flag (0x00 disabled, 0x80 enabled) 0x01-0x6C Name of application that produce Pokémon Link Data 0x6D-0x6E NULL terminator? 0x6F-0x94 Unknown/Unused 0x95-0x98 Unknown/Unused (0x00000000) 0x99-0x9C Pokémon transfer flags?1 (see notes) 0x9D-0x13C Pokémon slot 1 (160 bytes 2 see notes) 0x13D-0x140 Unknown/Unused (0x00000000) 0x141-0x144 Pokémon transfer flags?1 (see notes) 0x145-0x1E4 Pokémon slot 2 (160 bytes 2 see notes) 0x1E5-0x1E8 Unknown/Unused (0x00000000) 0x1E9-0x1EC Pokémon transfer flags?1 (see notes) 0x1ED-0x28C Pokémon slot 3 (160 bytes 2 see notes) 0x28D-0x290 Unknown/Unused (0x00000000) 0x291-0x294 Pokémon transfer flags?1 (see notes) 0x295-0x334 Pokémon slot 4 (160 bytes 2 see notes) 0x335-0x338 Unknown/Unused (0x00000000) 0x339-0x33C Pokémon transfer flags?1 (see notes) 0x33D-0x3DC Pokémon slot 5 (160 bytes 2 see notes) 0x3DD-0x3E0 Unknown/Unused (0x00000000) 0x3E1-0x3E4 Pokémon transfer flags?1 (see notes) 0x3E5-0x484 Pokémon slot 6 (160 bytes 2 see notes) 0x485-0x488 Unknown/Unused (0x00000000) 0x489-0x48A Item 1 (3 see notes) 0x48B-0x48C Item 1 quantity 0x48D-0x48E Item 2 (3 see notes) 0x48F-0x490 Item 2 quantity 0x491-0x492 Item 3 (3 see notes) 0x493-0x494 Item 3 quantity 0x495-0x496 Item 4 (3 see notes) 0x497-0x498 Item 4 quantity 0x499-0x49A Item 5 (3 see notes) 0x49B-0x49C Item 5 quantity 0x49D-0x49E Item 6 (3 see notes) 0x49F-0x4A0 Item 6 quantity 0x4A1-0x4A2 Battle Points (max. value 9999) 0x4A3-0x4A4 Poké Miles 0x4A5-0xA44 Unknown/Unused (All 0x00) 0xA45-0xA46 CRC-16/CCITT checksum for 0x01-0xA44 data When no Pokémon Link Data is available, 0x01-0xA46 is set to 0x00. Pokémon slot structure Offset Description 0x00-0x01 TID 0x02-0x03 SID 0x04 Pokemon Origin Game (OT Game ID) 00 for Game Received in 0x05-0x07 Unknown/Unused (0x000000) 0x08-0x0B [Pokemon] Encryption Constant Unset = 00000000 0x0C Primary Ribbons Ribbon data available below. 0x0D Secondary Ribbons Ribbon data available below. 0x0E PokéBall 0x0F Unused/Unknown 0x10-0x11 Held Item 0x12-0x13 Move ID #1 0x14-0x15 Move ID #2 0x16-0x17 Move ID #3 0x18-0x19 Move ID #4 0x1A-0x1B PokéDex Number (4 see notes) 0x1C Form No. 0x1D Language 00 for Game Received In 0x1E-0x37 Pokémon Nickname Null terminator for last two bytes. If no nickname, all 00. 0x38 Nature FF - Unset 0x39 Pokémon Gender 00 - Male 01 - Female 02 - Genderless 03 - Random 0x3A Pokémon Ability 00 - Ability 1 01 - Ability 2 02 - Dream World Ability 03 - RND(Abil1, Abil2) 04 - RND(Abil1, Abil2, AbilDW) 0x3B PID Toggle 00 - Generate Specified PID (from 0x6C-0x6F) 01 - Generate Random PID (Can be shiny) 02 - Generate Shiny PID (Always shiny) 03 - Generate Random PID (Can't be shiny) 0x3C-0x3D Egg Met Location (5 see notes) 0x3E-0x3F Met Location of Pokémon (5 see notes) 0x40 Met Level 0x41-0x46 Contest Stats Last byte is Sheen 0x47-0x4C IVs FFs for unset IVs FE for priority 0x4D OT Gender 00 - Male 01 - Female 03 - Recipient's Gender 0x4E-0x67 OT Name Null terminator for last two bytes. If no set OT, all 00. 0x68 Current Level(random if set to 0) 0x69 Egg Flag 00 - Is Not Egg 01 - Is Egg 0x6A-0x6B 'Unknown' 0x6C-0x6F PID (used if PID toogle is 00) 0x70-0x71 Relearn Move 1 0x72-0x73 Relearn Move 2 0x74-0x75 Relearn Move 3 0x76-0x77 Relearn Move 4 0x78 OT Memory Intensity 0x79 OT Memory Line 0x7A-0x7B OT Memory TextVar 0x7C OT Memory Feeling 0x7D-0x9F Unknown/Unused/Reserved bytes Ribbon Set Flag Value 0x74 0x75 0x01 Battle Champ Ribbon World Champ Ribbon 0x02 Regional Champ Ribbon Birthday Ribbon 0x04 National Champ Ribbon Special Ribbon 0x08 Country Ribbon Souvenir Ribbon 0x10 National Ribbon Wishing Ribbon 0x20 Earth Ribbon Classic Ribbon 0x40 World Ribbon Premier Ribbon 0x80 Event Ribbon Empty Notes Pokémon transfer flags: for ORAS demo Glalie/Steelix this is set to 0x0001 0x0001; for Celebi and Johto starters 0x0000 0x0000. Somehow this sets a value in the XY/ORAS savegame that makes the game unable to receive the pokemon again, this is what makes Glalie/Steelix from ORAS Demo only be able to be received once per savegame. Removing that value from the savegame allows to import another Glalie/Steelix. Todo: add offset where that value is stored in XY and ORAS. The statement that pokemon data is 160 bytes long is made due to this data being essentially the same as in wondercard data, which is 160 bytes long from TID to end of file. If item is not valid, it won't be obtained. If pokemon species is not valid (i.e 0x0000), no pokemon will be generated. Pokemon link will set egg met location to "Pokemon Link" and met at location to "Pokemon Link" regardless of the value in the data.
-
- structures
- technical references
-
(and 2 more)
Tagged with:
-
Hello all. As you may know, the Project Pokémon Wiki has a (rather extensive) documentation on the Diamond and Pearl save file structure. However, there is quite a bit of information missing from this page. Additionally, there is no documentation up regarding the Platinum save file structure. It would be of great benefit to save hacking developers (Sabresite and myself for example), as well as the wiki and site as a whole, if we could get these structures mapped out. And of course, anything that helps Sabresite helps PokéMod. If you have a means for extracting your Diamond / Pearl / Platinum save file(s), and a hex editor (like HxD), you can help map the save file structure by simply making a copy of your save file, making a change, saving, and comparing the previous save with the current save. (By the way, one of our members, evandixon, has created a toolkit to be used for save file mapping.) Additionally, I am going to create a small tool within the next few days with the express purpose of fixing the save file checksums in Diamond, Pearl, and Platinum. With this tool and a hex editor, you can edit the save file manually, and then load the save to see what changed. EDIT: And here it is. Things this thread has accomplished so far: There is a long list of things to look for specifically, and here are a few in no particular order (admins and mods feel free to edit this list): I will be constantly adding to and editing this post for more details. If anyone is interested in helping out or has any questions, post here, PM me, meet me on IRC, or check out our social group. If we get organized, we can have this thing done in no time, and that will ensure that we are ready to crack HeartGold and SoulSilver when the time comes. DateTimeBytes.zip Journal.zip
-
This is a clone of codemonkey85's thread, except this is for all of the spin-off games. Because no-one has bothered to mess with these games (or rather, anyone who has a clue what they are doing), there is no way to fix the checksum. We need that first to start pokeing locations. If we don't fix it, either nothing happens, or it says that the save is corrupt. If anyone is reading this, and has a clue what their doing, please find how to fix the checksum of Mystery Dungeon 2. Other spin-off games are welcome, because I'm not aware of any save file editors for ANY spin-off game. You will need a good HEX Editor, such as HxD. Good luck. Hello? Is anybody out there?