• 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.

[ASM & Hex] Changing the offset where a patch is applied

  • 28
    Posts
    11
    Years
    • Seen Nov 16, 2021
    Hey guys, I'm working on a hack and I downloaded a music patch because it was too much of stress trying to get sappy to work.

    The patch was the musical base by Squeetz, and it inserts data from 0x800000 to 0x8FFFFFF.

    I already have data here, so does anyone have any idea how I would go about changing where the patch is applied to?

    Thank youuuu
     
    Nevermind, I had an epic plan, I'm going to patch a blank rom, then copy the song table it creates. I'll paste it where I can find the space and then change the pointers from 00 00 80 08 to wherever I decide to put it instead. This should work right?
     
    Nevermind, I had an epic plan, I'm going to patch a blank rom, then copy the song table it creates. I'll paste it where I can find the space and then change the pointers from 00 00 80 08 to wherever I decide to put it instead. This should work right?

    I think yes, but let us know if it worked.
     
    Nevermind, I had an epic plan, I'm going to patch a blank rom, then copy the song table it creates. I'll paste it where I can find the space and then change the pointers from 00 00 80 08 to wherever I decide to put it instead. This should work right?

    I think yes, but let us know if it worked.

    Only flaw is that the actual song pointers within x800000 - x8FFFFF will be wrong.
    Though I believe @castlemurphy already solved this issue by copying existing ID's through Sappy, or something similar.
     
    Only flaw is that the actual song pointers within x800000 - x8FFFFF will be wrong.
    Though I believe @castlemurphy already solved this issue by copying existing ID's through Sappy, or something similar.

    If they move the data then repoint the patch pointers themselves why would it still be wrong?
    wanna know for myself in case I ever need to move patched data.
     
    If they move the data then repoint the patch pointers themselves why would it still be wrong?
    wanna know for myself in case I ever need to move patched data.


    Suppose you move data to x900000 - x9FFFFF. All of the actual song pointers will be pointing to data between x800000. See the issue? Suppose a song's pointer is 80 29 81 08, and the offset x812980 has FF bytes. It'll mess up even if we move it to x900000, wouldn't it? Quoting @castlemurphy:
    I actually figured out that this would corrupt the rom seeing as the pointers for loops and everything would become mixed up.
     
    Suppose you move data to x900000 - x9FFFFF. All of the actual song pointers will be pointing to data between x800000. See the issue? Suppose a song's pointer is 80 29 81 08, and the offset x812980 has FF bytes. It'll mess up even if we move it to x900000, wouldn't it? Quoting @castlemurphy:

    I still don't see the problem, if you know where the pointers are, why not just repoint them to the new location where the data actually is?
     
    That would mean to repoint every song (256 in total), not to mention that there will be tons of data we don't even know was repointed where.

    See now that makes sense. ok last question, is there no patch log that tells what moved where, the few times I've applied patches I think a file was created with that data. I'm not very good at reading it, but I'm guessing that's what it said.
     
    See now that makes sense. ok last question, is there no patch log that tells what moved where, the few times I've applied patches I think a file was created with that data. I'm not very good at reading it, but I'm guessing that's what it said.

    I don't think patches create log files; there is IPS Checker by LSA, but that's kinda different. Only the user who created said patch can provide offsets.
     
    I don't think patches create log files; there is IPS Checker by LSA, but that's kinda different. Only the user who created said patch can provide offsets.

    gotcha and yeah what I was using was an ips patch. I was applying phy special split, with an ips patch and that created a log file when it was done.
    That may be the only one I've seen do that, but I haven't used many anyway and just can't remember right now.
     
    Last edited:
    Back
    Top