• Our software update is now concluded. You will need to reset your password to log in. In order to do this, you will have to click "Log in" in the top right corner and then "Forgot your password?".
  • 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.

[ASM & Hex] How do you clear empty space in the middle of a ROM Hack?

Marky Vigoroth

...I just liked the Skarmory icon.
171
Posts
8
Years
I saw tha the game Pokémon Adventure: Red Chapter actually had some regions o free space in the middle. However, trying to trim that free space either leaves a blank screen or gets rid of the sound. I figure that getting rid of the free space messes up some pointers.
The reason why I wan to do th is because the ROM is just a bit over 32MB, which makes the game incompatible wi th Everdrive X flashcart and 3DS Virtual Console injections.
 

Asith

Uwao
237
Posts
3
Years
  • Age 22
  • Seen Apr 13, 2024
I suppose that depends on how much over 32 mb it is. I'm no expert, but trying to put stuff in that free space sounds like the right track, but just shifting everything won't really work.
Do you use HexManiacAdvance? It makes it really easy to move things because you can click on a offset/anchor and see everything that points to it - therefore you can move data and then easily change all pointers you need. I recommend you grab that tool and start moving chunks of data at a time from the end of the rom into free space and changing its pointers.
Additionally, you should only move data to word-aligned offsets, which means the offset should end in 0, 4, 8, or C (like 0x1006110, or something) so it can be read.
Of course, this is all assuming that data at the very end of the rom can even be moved safely. Again, not my area of expertise
 
135
Posts
4
Years
  • Age 33
  • Seen Mar 26, 2024
I was pretty sure that there is no way a Pokémon ROM can function when the ROM itself has bytes defined after 0x1 FF FF FF because 0x2 00 00 00 is where RAM starts. In other words, I thought you could not play a ROM anywhere if the size is above 32 megabytes. Anyway, you will have to copy−paste anchors into chunks of FF bytes to condense the ROM.
 
438
Posts
6
Years
  • Age 37
  • Seen Apr 20, 2024
I saw tha the game Pokémon Adventure: Red Chapter actually had some regions o free space in the middle. However, trying to trim that free space either leaves a blank screen or gets rid of the sound. I figure that getting rid of the free space messes up some pointers.
The reason why I wan to do th is because the ROM is just a bit over 32MB, which makes the game incompatible wi th Everdrive X flashcart and 3DS Virtual Console injections.

GBA roms cannot normally be larger than 32MB. I'm not sure if any emulators even support larger roms than that. Emulators tend to just ignore any data past 32MB, so you should be able to remove the data at the end to make the rom 32MB.
 

Marky Vigoroth

...I just liked the Skarmory icon.
171
Posts
8
Years
I suppose that depends on how much over 32 mb it is. I'm no expert, but trying to put stuff in that free space sounds like the right track, but just shifting everything won't really work.
Do you use HexManiacAdvance? It makes it really easy to move things because you can click on a offset/anchor and see everything that points to it - therefore you can move data and then easily change all pointers you need. I recommend you grab that tool and start moving chunks of data at a time from the end of the rom into free space and changing its pointers.
Additionally, you should only move data to word-aligned offsets, which means the offset should end in 0, 4, 8, or C (like 0x1006110, or something) so it can be read.
Of course, this is all assuming that data at the very end of the rom can even be moved safely. Again, not my area of expertise
The ROM hack has 1.131 extra bytes.
I do not know of HexManiacAdvance... I might check ou that...

UPDATE: That worked! Thank you all!!!
 
Last edited:
Back
Top