• Just a reminder that providing specifics on, sharing links to, or naming websites where ROMs can be accessed is against the rules. If your post has any of this information it will be removed.
  • Ever thought it'd be cool to have your art, writing, or challenge runs featured on PokéCommunity? Click here for info - we'd love to spotlight your work!
  • Which Pokémon Masters protagonist do you like most? Let us know by casting a vote in our Masters favorite protagonist poll here!
  • Red, Hilda, Paxton, or Kellyn - which Pokémon protagonist is your favorite? Let us know by voting in our poll!
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

[EM] hex values and free space

JordanB500

Former Pokemon League Champion
  • 104
    Posts
    17
    Years
    so i was going through my roms and i tested a patch that i made some time ago which i had to reconstruct from a fixed offset back to a dynamic base simply because the offset i used caused sound problems and in extreme cases caused the entire city of petalburg to disappear therefore i wanted to be sure of which offset to start my dynamic scripts from? so i looked thru the standard emerald rom with HxD and found that from 0xDE4020 to 0xE3C540 is 00 bytes not FF bytes so i am wondering since there is so much of it, is it safe to convert to free FF bytes? all without expanding the rom? or do i use 0xE3CF80? till the end of the rom?
     
    Curious about this myself since I am trying to establish a base for a ROM to use to start hacking while implementing CFRU/DPE (along with the recommended additions per CFRU's documentation) for Pokemon FireRed, and trying to understand the best way to utilize the ROMs free spaces while implementing these scripts (that is, trying to understand the best way to apply DPE --> recommended script --> recommended...etc.).

    In response to the original post, however, I would highly recommend looking into getting FreeSpaceFinder (can't post the link since I'm still under five posts, but it should be available in the Resources section of this the ROM Hacking thread), which will be able to open up your ROM and point you to the offsets in it that are free to use.
     
    so i was going through my roms and i tested a patch that i made some time ago which i had to reconstruct from a fixed offset back to a dynamic base simply because the offset i used caused sound problems and in extreme cases caused the entire city of petalburg to disappear therefore i wanted to be sure of which offset to start my dynamic scripts from? so i looked thru the standard emerald rom with HxD and found that from 0xDE4020 to 0xE3C540 is 00 bytes not FF bytes so i am wondering since there is so much of it, is it safe to convert to free FF bytes? all without expanding the rom? or do i use 0xE3CF80? till the end of the rom?

    Some of those 00 bytes are free space, but others aren't and should be left unchanged. If you want to be completely safe you can just use the space between 0xE3CF64 and the end of the ROM, as that's all unused 0xFF bytes. That said, according to this post some of the 00 bytes can be used if you really want to.

    Also, there's no downside to expanding the ROM; even though some old tools can't work with memory addresses after 0xFFFFFF, you can just reserve all the free space before that for those tools and put any "big" data in the expanded half.
     
    all of the ways in which im capable of expanding the rom end up doubling the size to 32 megabytes is there a way to choose the filesize?(To be honest there is more then enough space for my needs but i may want extra space in case i want to add more)
     
    all of the ways in which im capable of expanding the rom end up doubling the size to 32 megabytes is there a way to choose the filesize?(To be honest there is more then enough space for my needs but i may want extra space in case i want to add more)

    Honestly 32 MB is enough for a hack; there should be no need for more. But once the wise Lunos said that the GBA movie cartridges have 64 MB. So you can ask the creator of some movie cartridge about this.
     
    all of the ways in which im capable of expanding the rom end up doubling the size to 32 megabytes is there a way to choose the filesize?(To be honest there is more then enough space for my needs but i may want extra space in case i want to add more)

    You could do that with a hex editor; copy a chunk of the ROM that's the size of the extra space you want, paste it at the end of the 16MB ROM, then overwrite the new space with 0xFF bytes. Unless you've got an expanded Pokedex you probably won't need to expand the ROM at all though; there's almost two megabytes of free space, and that's more than enough for most things.
     
    Back
    Top