The PokéCommunity Forums  

Go Back   The PokéCommunity Forums > ROM Hacking > Research & Development
Sign Up Rules/FAQ Live Battle Blogs Mark Forums Read

Notices

Research & Development Got a well-founded knack with ROM hacking? Love reverse-engineering the Pokémon games? Or perhaps you love your assembly language. This is the spot for polling and gathering your ideas, and then implementing them! Share your hypothesis, get ideas from others, and collaborate to create!
Research & Development programs in this forum are subject to moderator approval before they are displayed.


Advertise here

Reply
 
Thread Tools
  #1    
Old April 4th, 2013, 12:04 PM
aar2697
 
Join Date: Jun 2010
Age: 17
Gender: Male
Send a message via Skype™ to aar2697

Advertise here
After a 7 month break, I have finally returned to ROM hacking. Today, I have finished learning about all the bytes in the map header. I am hoping this information will be helpful to you all working on your ROM hacks.

You can see the map header by pressing CTRL+H while you are in the header tab on your map in Advance Map. It is a long strand of bytes that the game uses to load everything for the map.

For example, the map header for Mt. Moon is this..
A43D7608 DCA17308 00000000 00000000 2001 72 00 7F 00 00 04 01 06 00 00

Now, I will go through all the bytes and explain what they mean. Experiment or use different maps as examples to get what you want.

Bytes 1-4: Pointer to map footer offset
Bytes 5-8: Pointer to event offset
Bytes 9-12: Pointer to map script offset
Bytes 13-16: Pointer to connection offset
Bytes 17-18: Music in reverse hex form.

Byte 19: Map footer #. Used for setmapfooter command, which changes the map to another. You should probably leave it be unless you're adding a new map.

Byte 20: ??

Byte 21: Defines what map name the map belongs to. (Thanks to Jambo51 for clearing this up)

Byte 22: Cave type

Byte 23: Weather type

Byte 24: Similar to byte 28. The trainer battle background may or may not change depending on the value chosen.

Byte 25: Set to 01 to be able to ride a bicycle on the map.

Byte 26: Changes the "Show name on entering" value that is visible in simple header mode. 06, 07 allow you to run on the map, 05, 08 do not.

Byte 27: Species floor number. Above-ground floors count up from 01, where 01 is "F1." Below-ground (basement) floor count down from FF, where FF is "BF1."

Byte 28: Species a battle background that will override the trainer battle background AND wild battle background. Leave at 00 if you do not want this. You can choose from 00-09. 0A and on seem to be the same background. This may be because I have JPAN's engine installed, but I'm not quite sure.

Perhaps someone knows what the twentieth byte is. If so, please say so and I will put it in this post.

Last edited by aar2697; April 5th, 2013 at 12:12 AM. Reason: Important change to byte 21
Reply With Quote
  #2    
Old April 4th, 2013, 04:31 PM
Spherical Ice's Avatar
Spherical Ice
Community Supporter
 
Join Date: Nov 2007
Location: UK
Send a message via Skype™ to Spherical Ice
Setting Byte 25 to 06 seems to work if you insert a map and you can't run in-game. I don't know if 01 does the same, it's just something I've always done when inserting maps.
__________________

Last edited by Spherical Ice; April 5th, 2013 at 04:27 AM.
Reply With Quote
  #3    
Old April 5th, 2013, 05:28 AM
Spherical Ice's Avatar
Spherical Ice
Community Supporter
 
Join Date: Nov 2007
Location: UK
Send a message via Skype™ to Spherical Ice
If the map names go over FF, maybe the twentieth byte was in case it went to 100?
__________________
Reply With Quote
  #4    
Old April 5th, 2013, 05:47 AM
Jambo51's Avatar
Jambo51
Glory To Arstotzka
 
Join Date: Jun 2009
Gender: Male
Nature: Quiet
Nope, it's strictly a byte. With a lot of work and redefinition you could have more than 0xFF, but as things stand, no.
__________________
Hey guys, please check out my recreations of the gen 1 and 2 music on my custom engine at my SoundCloud! - Here!
Reply With Quote
Reply
Quick Reply

Sponsored Links


Advertise here
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Minimum Characters Per Post: 25



All times are UTC -8. The time now is 02:50 PM.


Style by Nymphadora, artwork by Sa-Dui.
Like our Facebook Page Follow us on Twitter © 2002 - 2014 The PokéCommunity™, pokecommunity.com.
Pokémon characters and images belong to The Pokémon Company International and Nintendo. This website is in no way affiliated with or endorsed by Nintendo, Creatures, GAMEFREAK, The Pokémon Company or The Pokémon Company International. We just love Pokémon.
All forum styles, their images (unless noted otherwise) and site designs are © 2002 - 2014 The PokéCommunity / PokéCommunity.com.
PokéCommunity™ is a trademark of The PokéCommunity. All rights reserved. Sponsor advertisements do not imply our endorsement of that product or service. User generated content remains the property of its creator.