• 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!
  • It's time to vote for your favorite Pokémon Battle Revolution protagonist in our new weekly protagonist poll! Click here to cast your vote and let us know which PBR protagonist you like most.
  • 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] NoMethod Error for Every Trainer Battle

  • 34
    Posts
    5
    Years
    • Seen Sep 20, 2024
    Code:
    ---------------------------
    Pokemon Essentials
    ---------------------------
    [Pokémon Essentials version 17.2]
    
    Exception: NoMethodError
    
    Message: undefined method `*' for nil:NilClass
    
    PokeBattle_AI:3273:in `pbRoughDamage'
    
    PokeBattle_AI:2809:in `pbGetMoveScore'
    
    PokeBattle_AI:3896:in `pbChooseMoves'
    
    PokeBattle_AI:3894:in `each'
    
    PokeBattle_AI:3894:in `pbChooseMoves'
    
    PokeBattle_AI:4330:in `pbDefaultChooseEnemyCommand'
    
    PokeBattle_Scene:2786:in `pbChooseEnemyCommand'
    
    PokeBattle_Battle:2591:in `pbCommandPhase'
    
    PokeBattle_Battle:2586:in `each'
    
    PokeBattle_Battle:2586:in `pbCommandPhase'
    
    
    
    This exception was logged in 
    
    C:\Users\MSI\Saved Games\Pokemon Essentials\errorlog.txt.
    
    Press Ctrl+C to copy this message to the clipboard.
    ---------------------------
    OK   
    ---------------------------

    Hey guys, I just suddenly got this Error thrown up and I absolutely can't figure out why. The only thing I've changed are music files, so I have no idea why my game suddenly won't let trainer battles occur. It happens on each turn of the trainer battle, and won't let them take actions. Does anyone have any insight? All help appreciated!
     
    I'm going to go ahead and assume that you've accidentally changed either the code or the data. Look at PokeBattle_AI line 3273, there's a name on the left of a *, and that's the value that's nil.
     
    Ah I did, I added in an item but used the wrong code for the damage modifier! I usually figure these things out as I post them, but thanks so much for the help anyways!
     
    Back
    Top