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

[Script] Altering rival's movement in Oak's Lab in Fire Red

  • 4
    Posts
    5
    Years
    • Seen today
    It always irked me that the starters in FR/LG are placed out of order in Oak's Lab at the beginning: it's Bulbasaur/Squirtle/Charmander, when in the Pokédex it goes Bulbasaur/Charmander/Squirtle. So, I wanted to switch the latter two so they're in order while keeping the rival's choice pokémon consistent.

    I already used Advance Starter to change both the player and the rival starters such that the rival still gets whatever pokémon has a type advantage to yours. However, the rival's movement is unchanged, so he will pick the incorrect pokéball from the table. I assume I only need to make changes to each pokéball's script on Advance Map or something, but I don't know what to actually alter. I'm pretty new to ROM hacking and know next to nothing about scripting - the only scripts I have touched are of a few marts in order to change the items they sell.
     
    You might wanna start by learning scripting in XSE and a very little about Hex editing at first. Rival's movement is activated from the pokeball you pick. If you pick Bulbasaur, the game runs a script like "you selected the first pokeball, so make the rival move to let him pick the third pokeball". It all happens in these tiny scripts:
    Spoiler:


    A simple fix would be to reroute the variable 4001 check. If you want to do scripting after learning XSE, you can do this:
    1. Write a script in a free space in your ROM like this:
    Spoiler:

    where UVWXYZ is the location of the free space. Remember this address because it will be important for repointing.

    2. Open your ROM in a Hex Editor (dont worry, we wont be doing complex hex here), preferably HxD
    Search for "DC 9C 16 08" hex values and replace them with "YZ WX UV 08" (According to the address of the free space). Do the replacement for everytime "DC 9C 16 08" pops up. What this basically does is tells the game to go to UVWXYZ instead of 169CDC

    Method 2: A bit complex but easier steps and saves ROM spaces:
    Open your ROM in HxD.
    Go to 169CE4 and replace FF 9C 16 with 0F 9D 16
    Go to 169CEF and replace 1F 9D 16 with FF 9C 16
    Go to 169CFA and replace 0F 9D 16 with 1F 9D 16
    Dont Ctrl+C Ctrl+V the hex codes because it will bug your game. Use Ctrl+B (paste-write) instead of Ctrl+V (paste-insert).
     
    Back
    Top