• 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 many in Pokedex?

3
Posts
5
Years
    • Seen Nov 17, 2019
    I'm new to ASM and ROM hacking, and because of that, I haven't quite figured out the best ways to find the information I need from the ROM. I'm using Firered as my test game since it's very heavily documented.

    I'm currently trying to write a c++ program that reads the ROM's bytes (like PGE or YAPE) and grabs the pokemon's information. Right now I'm trying to read out all of the pokemon names from 0x245EE0 to 0x2469b4. It works like it should, even running each name through the encoder/decoder that I wrote to give me ASCII.

    Here's the code I have for this part:
    Spoiler:

    I know that this code works but I'm kinda frustrated that I can't find any reference to where the game keeps the number of pokemon. I could set up a check to make sure that the 11 bytes never read "AC FF 00 00 00 00 00 00 00 00 00" (which is the case with the entry after CELEBI). I just think that there must be a better way. I've tried to find any information through the multitudes of forum posts, but I'm just lost now.

    Any help would be appreciated.
     
    3
    Posts
    5
    Years
    • Seen Nov 17, 2019
    I've found some more information.

    Using DoesntKnowHowToPlay's post on FireRed pokedex expanding, I found some in game pointers to the length of the pokedex. 0x103920 relates to the data "malloc'd" for the pokedex, 0x88ea4 relates to the pokedex count on the title screen and trainer card, and 0x104c28 relates to the count on the pokedex menu.

    All of these locations have the value 385 (0x81010000 -little endian-) which relates to the pokedex count. If I skip the beta unown locations (252-276), this allows me to read out all of the names stored at 0x245EE0.

    Sorry if this post sounds really confusing. I'm not really used to using forums.

    PS: I'm not allowed to post links until after my 5th post, so the thread I'm referencing is "[FR] Expanding The Pokedex"
     
    Back
    Top