• 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?".
  • Forum moderator applications are now open! Click here for details.
  • 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.

Research: Experience Hacking

Mr.Pkmn

Ordinary ASM Magician
53
Posts
15
Years
  • Seen Nov 17, 2023
"How can leveling Pokemon be made less boring?": that is the question.

This is something that bothered me some time ago. When you complete the original game or normal difficulty hacks, your team rarely surpass lv 60. Challenging hacks may require you to grind up to lv 80-90, but the experience needed to reach those levels is 2-3 times the experience to reach lv 50, which can be very frustrating.

So I came to the conclusion that modifying the way the game gives you the experience or the required experience to gain a level could be a way to solve this problem and speed up things (& ending the game with lv 100 pokes). Since i can't ASM hack, i chose the second way.

Hacking the experience table
In Fire Red, around 0x253AE8, there's a table with all the values of the experience curve function stored in double words. Different tables for the different functions (erratic, fluctuating, medium-slow ecc..) exist, leaving the possibility of creating a custom function: linear, parabolic, logarithmic, exponential (lol no), piecewise ecc...
These functions are stored in this order:
Medium-Fast
Erratic
Fluctuating
Medium-Slow
Fast
Slow
Medium-Fast
Medium-Fast
Don't ask me why there are three Medium-Fast groups (the real one is the first). This might be exploited to create new experience curves (eg: super slow only for legendaries).

I made this video for testing purposes:




Hacking the experience gain formula
This area needs research, but it can potentially do neat things like give a biased value of experience based on the level like in BW, or change the equation from linear to parabolic in order to gain more experience at higher levels.


My own implementation (Patch included)
I've decided to simply reduce the pendency of the original curves by dividing their values by a factor which is increased as the level rises. You can see the effect with this graph (old medium-fast compared to new):

h**p://i52.tinypic.com/2lrlu8.png

- Little to nothing changes up to level 30+
- The same experience required to reach lv 50 now allows you to reach lv 59
- The total experience to reach lv 100 is now halved

This graph shows you how the new curve follows the experience gained from battle:

h**p://i56.tinypic.com/wv69t0.png

Obviously this won't solve the problem of grinding at the lower levels, but you can create your own reducing factor. Please note that an excessive lowering of the needed experience to lv 100 can shorten the lifespan of your hack!
 

RHIOneAlbum

Banned
214
Posts
12
Years
Interesting way to come across the question. Usually people just make the poke on give out more exp, or add more trainers, both of which are semi good ideas. But I can also see problems with this, the faster exp groups make it hard to grow early, but easier later on. You are right that wed have to edit the entire group to make it satisfying to players. Would it glitch up though?
 

Mr.Pkmn

Ordinary ASM Magician
53
Posts
15
Years
  • Seen Nov 17, 2023
Interesting way to come across the question. Usually people just make the poke on give out more exp, or add more trainers, both of which are semi good ideas. But I can also see problems with this, the faster exp groups make it hard to grow early, but easier later on. You are right that wed have to edit the entire group to make it satisfying to players. Would it glitch up though?
This is the most flexible solution, as you can shape the curve for your own needs. My need was reaching lv 100 in a faster way. You may change all pokemon from the Erratic group to the Fast group, or generate a level curve with all values halved. The latter though retains the hard part from lv 50 to lv 100, so while it makes all things faster (especially at the beginning) you'll still have to grind a lot for the final levels.

In a new game I haven't encountered any glitch, you can also check the video. It might create problems if you already had a save file with the old experience table though.
 

~Anbuja

Let's Keep It Simple
321
Posts
13
Years
to tell the truth i dont really get the point of shrinking the exp requiriment to rise the v of the pokemon how u did , i wouldt want to get an charizard lv 100 at brock the thing to train them hard and get mroe playtime is the uniqe thing at hacks for me not speeding the game to end it faster.
but this is just my opinion:)
 

RHIOneAlbum

Banned
214
Posts
12
Years
Aight, good discovery then. I still don't think it will take over as totally cool and standard, but nice to know that people can do this now. Good job :D
 

Deokishisu

Mr. Magius
989
Posts
18
Years
There is a minor problem that might occur with lowering the experience required to get to certain levels. When trading to games not patched with this (or the stock Nintendo games), the levels would likely be reset to whatever they would be with that amount of experience normally when deposited into a box and withdrawn, as stats and such are recalculated upon doing so. Disregard this if experience values and levels aren't recalculated similarly, as I just have a basic understanding of what values go through this check when it happens.

EDIT: The solution would obviously be to keep the required experience to get to max level the same, and increase the amount of experience earned as a Pokemon levels, as opposed to lowering the requirements as it levels.
 

Mr.Pkmn

Ordinary ASM Magician
53
Posts
15
Years
  • Seen Nov 17, 2023
There is a minor problem that might occur with lowering the experience required to get to certain levels. When trading to games not patched with this (or the stock Nintendo games), the levels would likely be reset to whatever they would be with that amount of experience normally when deposited into a box and withdrawn, as stats and such are recalculated upon doing so. Disregard this if experience values and levels aren't recalculated similarly, as I just have a basic understanding of what values go through this check when it happens.

EDIT: The solution would obviously be to keep the required experience to get to max level the same, and increase the amount of experience earned as a Pokemon levels, as opposed to lowering the requirements as it levels.
I don't know if this is much of a problem since most hacks are played as standalone games. Some hacks are even more incompatible if they replaced pokemon with fakemon or modified the base stats and such.
Yes, the solution is hacking the experience gain formula but i don't know how we can do it. If it is SO important you can add the difference to all levels while maintaining the new experience curve. This will make lv 100 pokemon compatible with the other games.
 

TheDarkShark

Metal Headed Hacker
56
Posts
13
Years
Hacking the formula shouldn't be as hard to do, as it seems (I hope so at least). Simply find the Pokémon's data offset in the RAM, put a break point on write to that offset and change the routine that looks like it could be the one calculating the gained EXP, if there's more than one. I'll see what I can do, but better don't trust into my ASM knowledge too much ;)
 

Jambo51

Glory To Arstotzka
736
Posts
14
Years
  • Seen Jan 28, 2018
Hacking the formula shouldn't be as hard to do, as it seems (I hope so at least). Simply find the Pokémon's data offset in the RAM, put a break point on write to that offset and change the routine that looks like it could be the one calculating the gained EXP, if there's more than one. I'll see what I can do, but better don't trust into my ASM knowledge too much ;)

I've already managed to hack the experience formula. I will tell you right now, it's HARD. It's not laid out all nice and simple for you to find.

However, keeping in with this thread , I CAN tell you where the game writes the totalled up experience to (That is, the result of the Experience Formula).

I can't remember where in the rom exactly this happens, but the game writes the experience gain to 0x02023D50. I hope this will help people to come up with new and interesting ways of using exp gain. This is for the battle exp gain formula. The experience gaining types (slow, erratic etc) all use a LOOK UP table. I don't have the location of said table unfortunately, so you'll have to look it up yourself.

Hope this helps! :D
 

Mr.Pkmn

Ordinary ASM Magician
53
Posts
15
Years
  • Seen Nov 17, 2023
The experience gaining types (slow, erratic etc) all use a LOOK UP table. I don't have the location of said table unfortunately, so you'll have to look it up yourself.
If i didn't know i wouldn't have opened this topic ;)
 
Back
Top