View Single Post
  #23    
Old May 8th, 2008 (01:27 AM).
glenn14256
Beginning Trainer
 
Join Date: May 2008
Gender:
Hi everyone!

I need some help with trainer battles. I got it to work and all, and even the custom Pokemon and trainer sprites work properly. But I keep getting this error when battling a trainer. I think it has something to do with a script error making the trainer clueless on what to do next, the result -> it won't do anything at all. This is the error:

Exception: NameError
Message: undefined local variable or method `attacker' for #<PokeBattle_Battle:0x5740760>
PokeBattle_AI:515:in `pbEnemyShouldWithdraw?'
PokeBattle_ActualScene:2209:in `pbChooseEnemyCommand'
PokeBattle_Battle:2333:in `pbCommandPhase'
PokeBattle_Battle:2328:in `each'
PokeBattle_Battle:2328:in `pbCommandPhase'
PokeBattle_Battle:722:in `pbStartBattleCore'
PokeBattle_Battle:721:in `logonerr'
PokeBattle_Battle:721:in `pbStartBattleCore'
PokeBattle_Battle:705:in `loop'
PokeBattle_Battle:734:in `pbStartBattleCore'

"#<PokeBattle_Battle:0xXXXXXXX>" (XXXXXXX is dynamic depending on which trainer you battle).

I would really like to get some help with this. So thanks in advance!