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

[Error] FATAL ERROR: When my max-EVs Pokemon wins a battle, the game crashes because he can't gain any more EVs!

  • 429
    Posts
    4
    Years
    [Pokémon Essentials version 19.1]
    [Generation 8 Project v1.1.0]
    [v19.1 Hotfixes 1.0.7]

    Exception: ArgumentError
    Message: min argument must be smaller than max argument

    Backtrace:
    174:Battle_ExpAndMoveLearning:85:in `clamp'
    174:Battle_ExpAndMoveLearning:85:in `block in pbGainEVsOne'
    111:Stat:28:in `block in each_main'
    101:GameData:58:in `block in each'
    101:GameData:58:in `each'
    101:GameData:58:in `each'
    111:Stat:28:in `each_main'
    174:Battle_ExpAndMoveLearning:83:in `pbGainEVsOne'
    174:Battle_ExpAndMoveLearning:38:in `block (2 levels) in pbGainExp'
    172:PokeBattle_Battle:392:in `block in eachInTeam'

    Why is this happening?
     
    Last edited:
  • 95
    Posts
    4
    Years
    You use a clamp method for an number (integer of float).
    The first number indicated on your clamp range is greater than the second

    Code:
    number.clamp(min_number,max_number)
    min_number must be equal or inferior of max_number

    I think you wrote
    Code:
    ev.clamp(252,0)
    instead of
    Code:
    ev.clamp(0,252)
    (or something similar)
     
  • 24
    Posts
    2
    Years
    One more time thanks for your help to solve error......
    To solve error go to Scripts in your RPG XP scripts editor find Pokemon name script in Pokemon Script section
    go to line 95

    change EV_LIMIT = 1512(defualt value is arroud 500)

    see SS in for help.

    explanation in spoilers
    Spoiler:


    Note EV_LIMIT = 510 is default value in Pokemon essentials 19.1 so backup original script before change. it may cause bug.
     
    Back
    Top