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

Code: Complete FireRed Upgrade

Chaotix

Love to test
59
Posts
17
Years
    • Seen Jan 11, 2020
    Is it possible to edit type advantages through the engine? I see references to an attack bank and a def bank in the c code for damage calculation but can't seem to figure out where they are from. If not, is the type advantage chart repointed? I can't find it in the generated offsets file.

    They are in assembly/data/type_tables.s. I haven't tried to edit it myself yet but should be fine. In offsets.ini the repointed table is the label "gTypeEffectiveness".
     

    Child Amnesiac

    Ever changing
    341
    Posts
    5
    Years
  • I have question:
    What are the other type numbers for the Z crystals IE. 2= Flying. I can't seem to find anything in the file to help me out. Same thing goes for the signature Z crystals.
     

    Chaotix

    Love to test
    59
    Posts
    17
    Years
    • Seen Jan 11, 2020
    I have question:
    What are the other type numbers for the Z crystals IE. 2= Flying. I can't seem to find anything in the file to help me out. Same thing goes for the signature Z crystals.

    I haven't personally messed with Z-moves or anything like that but the types are in include/constants/pokemon.h. For example normal is 0x0, Fighting is 0x1, Flying is 0x2, etc. Just match the numbers there for making type Z-Crystals. Not sure about the specials ones still though, not enough time right now to look into it more deeply.
     

    Child Amnesiac

    Ever changing
    341
    Posts
    5
    Years
  • I haven't personally messed with Z-moves or anything like that but the types are in include/constants/pokemon.h. For example normal is 0x0, Fighting is 0x1, Flying is 0x2, etc. Just match the numbers there for making type Z-Crystals. Not sure about the specials ones still though, not enough time right now to look into it more deeply.

    Thanks! If that's how the moves are listed, then the signature move order should be stored in src\set_z_effect.c

    Edit: I think it has to do with the name.
     
    Last edited:

    Chaotix

    Love to test
    59
    Posts
    17
    Years
    • Seen Jan 11, 2020
    It's fantastic but i have a question.
    Spoiler:

    The 'code' is just referring to all the data that the CFRU inserts. It's saying you can open scripts/make.py and change the line: OFFSET_TO_PUT = 0x900000 - if you want to change where it will put everything. By default there is nothing there in Fire Red so it is safe to use; but if you had already used that area on your hack and didn't want to lose what was there already you can change the offset so it goes somewhere else.
     

    Zankew

    (▀̿Ĺ̯▀̿ ̿)
    158
    Posts
    5
    Years
  • Thanks. I will now use in my ROM. Thankfully, I did not implement anything. So I guess keeping the offset at 0x900000 will be alright.
     

    Zankew

    (▀̿Ĺ̯▀̿ ̿)
    158
    Posts
    5
    Years
  • I have a noob question.
    when i try to execute make.py in cmd, it says no rom named BPRE0.gba exists. Am i doing something wrong?
     

    Chaotix

    Love to test
    59
    Posts
    17
    Years
    • Seen Jan 11, 2020
    I have a noob question.
    when i try to execute make.py in cmd, it says no rom named BPRE0.gba exists. Am i doing something wrong?

    Do you have BPRE0.gba in the main section of the project? Thats the file it uses to do the changes; its just a base Fire Red 1.0 that you re-name to BPRE0. If you have one there and it is giving you that message you probably have it named BPRE0.gba.gba or something like that.
     

    Zankew

    (▀̿Ĺ̯▀̿ ̿)
    158
    Posts
    5
    Years
  • Do you have BPRE0.gba in the main section of the project? Thats the file it uses to do the changes; its just a base Fire Red 1.0 that you re-name to BPRE0. If you have one there and it is giving you that message you probably have it named BPRE0.gba.gba or something like that.

    Nope, thats not the case. I have BPRE0.gba in the main folder, but still that error is popping up.
     
    Last edited:
    2
    Posts
    5
    Years
    • Seen Apr 23, 2023
    Love the work.

    How does this engine work regarding overworld Sandstorm effects and in-battle sandstorm? For clarity, I'm specifically wanting the 50% special defense boost to Rock, Steel and Ground types when Sandstorm is in play during battle, and I'm not sure if this is something that should be listed in the engine (or I'd have to do something else to implement it).
     

    Chaotix

    Love to test
    59
    Posts
    17
    Years
    • Seen Jan 11, 2020
    Love the work.

    How does this engine work regarding overworld Sandstorm effects and in-battle sandstorm? For clarity, I'm specifically wanting the 50% special defense boost to Rock, Steel and Ground types when Sandstorm is in play during battle, and I'm not sure if this is something that should be listed in the engine (or I'd have to do something else to implement it).

    I just did a search of the CFRU for Sandstorm and I found in src/damage_calc.c a section for Sandstorm sp. def increase. Also I checked the official information on sandstorm since I didn't know about the sp. def increase and it only increases the sp. defense on Rock types, Steel and Ground do not receive that bonus.
     
    2
    Posts
    5
    Years
    • Seen Apr 23, 2023
    I just did a search of the CFRU for Sandstorm and I found in src/damage_calc.c a section for Sandstorm sp. def increase. Also I checked the official information on sandstorm since I didn't know about the sp. def increase and it only increases the sp. defense on Rock types, Steel and Ground do not receive that bonus.

    That's interesting! I always thought it was Steel and Ground types who received the Sp. Def boost as well. :O Thank you for the clarification. <3
     
    694
    Posts
    7
    Years
    • Seen Feb 22, 2024
    Not sure if this was fixed (I'm using a month old repo) but Foul Play doesn't take into consideration the stat changes for the target. I used swagger three times on a Pokemon then used Foul Play but it did the same amount on the same Pokemon before I used Swagger.
     

    Child Amnesiac

    Ever changing
    341
    Posts
    5
    Years
  • I have another couple of questions:
    1. Let's say I want to use HTE 1.0 to edit trainers (I know I'm going to get "use G3T instead", but hear me out)

    The offsets.ini file says that the data is stored at 09XXXXXX

    I insterted the CFRU at 0x1000000, so do I just replace the 9 with a 1?

    2. Where's the new move name table located at, (if I inserted it at 0x1000000)?
    and just how many moves are there? (Yet again, for HTE 1.0)
     
    3
    Posts
    11
    Years
    • Seen Oct 10, 2020
    Trying to compile (opened the cmd from the folder where the BPRE0 is located, but I get an error.
    I attached a screenshot to this post with the error that shows up in cmd.

    -I Installed python 3.8.1 and devkitpro
    -I have the following pathways
    C:\Users\James\AppData\Local\Programs\Python\Python38\;C:\devkitPro\devkitARM\bin\
    C:\Users\James\AppData\Local\Programs\Python\Python38\Scripts\;C:\devkitPro\devkitARM\bin\
    %USERPROFILE%\AppData\Local\Microsoft\WindowsApps\;C:\devkitPro\devkitARM\bin
    C:\Users\James\AppData\Local\Programs\Python\Python38\
    C:\Users\James\AppData\Local\Programs\Python\Python38\Scripts\

    - If I only have the first 3 paths and not the latter 2, then cmd says it doesn't recognize python.
    I'm sure that I used the right links C:\Users\James\AppData\Local\Programs\Python\Python38\ and C:\devkitPro\devkitARM\bin but for some reason it can't detect the devkitpro link.
     

    Attachments

    • screenshot.png
      screenshot.png
      14.7 KB · Views: 34

    Chaotix

    Love to test
    59
    Posts
    17
    Years
    • Seen Jan 11, 2020
    I have another couple of questions:
    1. Let's say I want to use HTE 1.0 to edit trainers (I know I'm going to get "use G3T instead", but hear me out)

    The offsets.ini file says that the data is stored at 09XXXXXX

    I insterted the CFRU at 0x1000000, so do I just replace the 9 with a 1?

    2. Where's the new move name table located at, (if I inserted it at 0x1000000)?
    and just how many moves are there? (Yet again, for HTE 1.0)

    From what I've tried HTE is actually better than G3T for editing trainers with CFRU. I didn't need to change any offsets that HTE reads to make it work; just open the BPRE.ini file and changed the number of pokemon (1102) and number of moves (810) and it was good to go.

    Trying to compile (opened the cmd from the folder where the BPRE0 is located, but I get an error.
    I attached a screenshot to this post with the error that shows up in cmd.

    -I Installed python 3.8.1 and devkitpro
    -I have the following pathways
    C:\Users\James\AppData\Local\Programs\Python\Python38\;C:\devkitPro\devkitARM\bin\
    C:\Users\James\AppData\Local\Programs\Python\Python38\Scripts\;C:\devkitPro\devkitARM\bin\
    %USERPROFILE%\AppData\Local\Microsoft\WindowsApps\;C:\devkitPro\devkitARM\bin
    C:\Users\James\AppData\Local\Programs\Python\Python38\
    C:\Users\James\AppData\Local\Programs\Python\Python38\Scripts\

    - If I only have the first 3 paths and not the latter 2, then cmd says it doesn't recognize python.
    I'm sure that I used the right links C:\Users\James\AppData\Local\Programs\Python\Python38\ and C:\devkitPro\devkitARM\bin but for some reason it can't detect the devkitpro link.

    Uhh whats up with the first 3 path variables? If it says it doesn't recognize python having the first 3 then the way you have it definitely isn't working. I would only have one path per line; trying to put devkitpro on the same line as another path probably isn't a good idea.
     
    Last edited:
    3
    Posts
    11
    Years
    • Seen Oct 10, 2020
    Thanks for getting back to me! 😊

    Never done this before so I don't really know how this path/compiling stuff works.

    I figured it out! 👍 I did the following for the pathways.

    C:\Users\James\AppData\Local\Programs\Python\Python38\
    C:\devkitPro\devkitARM\bin\
    C:\Users\James\AppData\Local\Programs\Python\Python38\Scripts\
    C:\devkitPro\devkitARM\bin\

    The pokemew instructions suggested putting ";C:\devkitPro\devkitARM\bin" at the end of each pathway of each directory. There wasn't an image or video showing what that would look like, so I guess that left me rather confused. The "one path per line" suggestion cleared things up for me. Thank you so much!
     
    Last edited:
    75
    Posts
    10
    Years
  • I do not want to seem demanding or annoying but I should do a complete tutorial on how to compile the complete repository with all pokemon, items, abilities, moves, mechanics ... the readme is not very understandable at least for me that I speak Spanish..

    Att.. Google Traslate ._.
     
    Back
    Top