• 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!
  • Our weekly protagonist poll is now up! Vote for your favorite Conquest protagonist in the poll by clicking here.
  • 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.

[Scripting Question] How to fix the Mimikyu error?

Cardboard Slime

A Slime in a Box
  • 19
    Posts
    7
    Years
    So someone made a code for Mimikyu disguise. I implement it but I got this error.

    [Pokémon Essentials version 17]
    Exception: NoMethodError
    Message: undefined method `hasBypassingAbility' for #<PokeBattle_Battler:0xa2eab78>
    PokeBattle_Move:1165:in `pbReduceHPDamage'
    PokeBattle_Move:1280:in `pbEffect'
    PokeBattle_Battler:2744:in `pbProcessMoveAgainstTarget_ebs'
    PokeBattle_Battler:2700:in `each'
    PokeBattle_Battler:2700:in `pbProcessMoveAgainstTarget_ebs'
    EliteBattle_0:475:in `pbProcessMoveAgainstTarget'
    PokeBattle_Battler:3176:in `pbUseMove_ebs'
    PokeBattle_Battler:3156:in `loop'
    PokeBattle_Battler:3179:in `pbUseMove_ebs'
    EliteBattle_0:508:in `pbUseMove'

    How to fix it?
    Here's the link: https://www.pokecommunity.com/threads/393760
    (i didn't want to nercopost, so i did a new thread.
     
    Last edited by a moderator:
    well, i just quote them and got works lol:

    Code:
          if opponent.effects[PBEffects::Disguise] #&& !attacker.hasBypassingAbility()
            #@battle.pbDisplayEffect(opponent)
            @battle.pbDisplay(_INTL("Its disguise served it as a decoy!"))
            opponent.effects[PBEffects::Disguise]=false
            opponent.form=1
            opponent.pbCheckForm
            @battle.pbDisplay(_INTL("disguise was busted!"))
            damage=0
          end

    i quote ' #&& !attacker.hasBypassingAbility()' and '#@battle.pbDisplayEffect(opponent)'

    But my mimikyu doenst changes sprite back in battle :/ could be coz that 'hasBypassingAbility()' make this...

    EDIT: my mimikyu and my opponent, do not change sprite form :/ only change in summary screen on the battle.
     
    Last edited:
    Back
    Top