- 11
- Posts
- 4
- Years
- Seen Nov 8, 2022
Hi,
I recently considered to make a new rom hack for pokemon emerald. (I've already made one, but that's not truly finished.) However, first I need to make sure that I want to make sure I can do anything I need to do. One thing I wanted to do is giving the enemy trainers a specific nature. With the help of A-Trainer and a hex-editor, I tracked the bytes responsible for the natures down. For example, for youngster Calvin (the first Trainer after you get the pokeballs) it's the bytes with offset 0x3131E4 to 0x3131E9.
However, as far as I can tell, you cannot set the natures using these bytes: They are chosen psydo-random using these six bytes for each pokemon. For example if Calvin has 6 pokemon and you change one of these bytes, all six pokemon get other natures. (If I'm wrong there, please tell me, but that's what I was able to learn from testing.)
After I was stuck there, I tried to get some solution in the internet, and found this: https://www.pokecommunity.com/threads/307117
Someone has solved this problem. However, he/she leaves some code and I've no clue how to use that.
So can anyone explain to me, how to get that solution working or alternatively how to make the psydo-random nature be what I want it to be?
Edit:
I looked more into it and somehow managed to get it running. (Not quite sure what I did different this time, but as long as it works, I'm happy)
I recently considered to make a new rom hack for pokemon emerald. (I've already made one, but that's not truly finished.) However, first I need to make sure that I want to make sure I can do anything I need to do. One thing I wanted to do is giving the enemy trainers a specific nature. With the help of A-Trainer and a hex-editor, I tracked the bytes responsible for the natures down. For example, for youngster Calvin (the first Trainer after you get the pokeballs) it's the bytes with offset 0x3131E4 to 0x3131E9.
However, as far as I can tell, you cannot set the natures using these bytes: They are chosen psydo-random using these six bytes for each pokemon. For example if Calvin has 6 pokemon and you change one of these bytes, all six pokemon get other natures. (If I'm wrong there, please tell me, but that's what I was able to learn from testing.)
After I was stuck there, I tried to get some solution in the internet, and found this: https://www.pokecommunity.com/threads/307117
Someone has solved this problem. However, he/she leaves some code and I've no clue how to use that.
So can anyone explain to me, how to get that solution working or alternatively how to make the psydo-random nature be what I want it to be?
Edit:
I looked more into it and somehow managed to get it running. (Not quite sure what I did different this time, but as long as it works, I'm happy)
Last edited: