• 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!
  • Which Pokémon Masters protagonist do you like most? Let us know by casting a vote in our Masters favorite protagonist poll here!
  • Red, Hilda, Paxton, or Kellyn - which Pokémon protagonist is your favorite? Let us know by voting in our poll!
  • 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.

Understanding the EV gain mechanic

  • 853
    Posts
    4
    Years
    • Seen Nov 9, 2023
    Firstly I'm soliciting anyone that knows about this, or for someone to research this, I'm not trying to be lazy here, I just don't have the knowledge yet to get this done, but I'll be working on it myself as well as I learn.
    But right now I don't even know where to begin to find something like this.

    The question is how does the stat gain from EV's work?
    I know final stats are based on a combination of base stats, IV's, nature, and EV's.

    EV's go to increasing your final stat value, but it also increases your current stats without you needing to level up.
    That's what I'm trying to look into. From booting up pokegen and putting in different ev values, I've noticed that putting in 200 Evs repeatedly gives a boost of 10 stat points. From that I guessed the function was stat increase from ev's is 1/20th of the EV's earned.
    (another way of looking at it, is 1/5th of the total earned stat increase can be accessed as soon as you earn it. one category Evs/4 to get stat increase by lvl 100. then dividing that by 5 showed how much it grew now.)

    That mostly holds up but when putting in 250 the value comes to 12.5, and if it worked like IV's you'd expect it to round down in every circumstance, making everything above 240 meaningless. But for some reason it rounds up to 13, but not always.

    Messing around with values I see that both nature & IV's affect this , nature possibly more than IV's.

    Given a neutral nature and a range of random IV's some stats stop at 12, while others would round up to 13, seemingly without pattern
    It could be linked to base stats but I assume not, because changing IV's alone changed which stats rounded up.

    Finally a negative nature, with the same IVs took a category that previously rounded up to 13, and capped it at 12,
    While a positive one boosted it up to 14

    That relationship remained mostly the same for a category that stopped at 12. positive nature boosted it up 1, to 13,
    while a negative one reduces it 1, to 11.
    I've also noted that in some cases for the category that caps at 12, if you earn 254 points another stat point is added "now" but of course not always, and at least a neutral nature is required.

    So I want to find is what the actual function is for your stats changing as you earn evs, and hopefully where in the code the argument is.

    Oh and I'm using black/white for this.
    Thanks.
     
    [I would have edited my post but at this time it was being moderated so I couldn't access my original post to edit]
    Ok so I feel stupid for not realizing this, before I posted but it was late, any way the proportion of the total stat increase you receive now isn't a static 1/20 or 1/5 of total stat gain.

    It occured to me i was testing this on a lvl 20 pokemon. *facepalm*
    So long story short the effect isn't static, but linear with relation to your pokemon's level in regards to the max level of 100.

    Because my croagunk was lvl 20, when I tested this first it just happened to come out to 1/5th of the stat gain was being received then, because 20 is 1/5th of 100.
    I tested this on a lvl 10 pokemon and it held up exactly as expected and they gained 1/10. In pokegen investing 250 evs which is 63 stat points by 100. the pokemon's stat went up 6 points.

    And so I'm actually providing something, here's what this potentially means.
    The actual formula for calculating how many stat points your pokemon will gain from ev investment is, EVs / 4 * (current lvl / max lvl) and then round down

    This part is my hypothesis or purely theoretical whatever,
    Anyway if all pokemon games use this and have an variable or something that defines max lvl as 100.
    Any romhack that increases the max lvl cap without also adjusting evs, will effectively be nerfing all pokemon.(at least early on)

    Because increasing the lvl cap changes the proportions for the lvl multiplier portion of the function/equation.
    So given same evs and a max stat increase of 63, pokemon would gain the same stat bonus by max level but much slower.

    To find how much slower, just divide 100 by whatever the new max level is. (100/new max level) This'll give a rate ex. 30% the original growth/gain rate
    but you can go further, if you multiply that rate by 100, and then divide 100 by that you can find how many more lvls players will have to invest to get the same gain they previously got at that level.
    ex. .30 x 100=30 100/30=+3.3 lvls to get same gain at old level. So given a growth rate of 30% the original players would have to be about +3 the level they would usually be to get the same gain.
    This essentially means you'd have to go up to level 13 to get the same bonus you'd normally get at 10.

    Luckily since our original max is 100, to get diminishing like this the max level would have to be set to 333.

    (but if you want to be extra nerdy, set the max to about 620 and you get what you normally gain at level ten at level 16.
    Now you're looking at me like what's the point in that? Well it makes pokemon essentially run on hexadecimal. *snort* *pushes glasses*
    You'd probably need to set an experience share mechanic or give multiple exp shares, as well as about triple exp gain, but its doable. imo)

    So takeaways, if you're planning to use increased max level as a difficulty metric know that you're essentially making EVs much less useful, IVs too because they work the same(except that IVs are already in stat form so don't need to be divided to convert). Natures are also affected by this.
    As they all work the same giving you some amount of stat change prorated over your percentage of max level. (current lvl / max lvl)

    On another note depending on how growth on lvl up works, it may be pointless to even raise lvl without manually changing stats, but that depends on if pokemon have preprogrammed max stats, or if they can just grow indefinitely unless limited by lvl/exp caps.

    Essentially is growth defined as a rate from the ceiling value, or a rate from the floor value.
     
    Last edited:
    well I feel dumb, looking on db I realized that health was calculated differently then I went to serebii and they broke down both of the calculations right there.

    Calculation
    This is how the stats are calculated;

    Hit Points:
    ( (IV + 2 * BaseStat + (EV/4) ) * Level/100 ) + 10 + Level

    Attack, Defense, Speed, Sp. Attack, Sp. Defense:
    (((IV + 2 * BaseStat + (EV/4) ) * Level/100 ) + 5) * Nature Value
     
    Back
    Top