The PokéCommunity Forums Fan Games ROM Hacking
ASM & Hex How to tell Fire red rom to use more than 2 bytes for Pokemon data in Hex code?

ROM Hacking Need a helping hand? You can get help on any ROM Hacking-related problems or questions you have here.

Reply
 
Thread Tools
  #1    
Old 1 Week Ago (3:54 AM). Edited 1 Week Ago by chazfoot.
chazfoot's Avatar
chazfoot chazfoot is offline
     
    Join Date: Jul 2018
    Location: London
    Gender: Male
    Posts: 55
    Hey all, an odd question. I've made some progress with evolutions, the game now supports 8 evolutions per Pokemon, using 6 bytes to store the data - first 2 for evo type, next 2 for level/item index/last 2 for Pokemon data. I was planning on hex editing all of this data, so far I have managed to test it successfully with Bulbasaur through to Charizard but a thought has occurred to me...

    I'm using Petuuuhhh's expanded rombase, so there are more than 0xFFFF Pokemon in the game, 0xFFFF is Snover. So how do I tell the game to use more than 2 bytes of data to read a pokemon's index number?

    Spoiler:
    EXAMPLE - So the hex data for Bulbasuar's evolutions, found in my rom at 0xB2BC14 would look like this;
    04 00 10 00 02 00. 04 00 to tell the game it evolves by reaching a certain level, 10 00 to tell the game what level (reverse the bytes - 0x0010 = DEC 16) and 02 00 for the index number of the evolution (0x0002 = Ivysaur);
    as per this very helpful post; https://www.pokecommunity.com/showthread.php?t=80204&highlight=8+evolutions


    Surely by this method the game will only recognise evolutions for Pokemon up to and excluding Snover. Do I need to switch all the Pokemon around to put all evolved forms within the first 512 index numbers, because that would take forever! Is there an easier way to tell the rom to just read 3 bytes, not 2?

    Thanks for any help guys, you tha best xxxxxx
    Reply With Quote
      #2    
    Old 1 Week Ago (7:48 AM).
    Koople's Avatar
    Koople Koople is offline
       
      Join Date: Nov 2016
      Nature: Relaxed
      Posts: 69
      Quote:
      Originally Posted by chazfoot View Post
      I'm using Petuuuhhh's expanded rombase, so there are more than 0xFFFF Pokemon in the game, 0xFFFF is Snover. So how do I tell the game to use more than 2 bytes of data to read a pokemon's index number?
      I'm not familiar with this rombase, but I'm skeptical that it has over 0xFFFF pokemon. That's more than 65000 pokemon.
      Reply With Quote
        #3    
      Old 1 Week Ago (3:09 PM).
      chazfoot's Avatar
      chazfoot chazfoot is offline
         
        Join Date: Jul 2018
        Location: London
        Gender: Male
        Posts: 55
        Ok then I'm definitely dumb and hexing wrong, I assumed 0XFFFF = 0XFF + 0XFF I guess you mulitiply instead?
        Reply With Quote
          #4    
        Old 1 Week Ago (3:13 PM).
        chazfoot's Avatar
        chazfoot chazfoot is offline
           
          Join Date: Jul 2018
          Location: London
          Gender: Male
          Posts: 55
          Wow I did some research and I'm super dumb lol XD Thanks dood xxxxx
          Reply With Quote
          Reply

          Quick Reply

          Join the conversation!

          Create an account to post a reply in this thread, participate in other discussions, and more!

          Create a PokéCommunity Account
          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

          Forum Jump


          All times are GMT -8. The time now is 9:03 AM.