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

How to use the $Trainer.shadowcaught array

  • 94
    Posts
    12
    Years
    • Seen May 4, 2018
    Hello. I've been trying to use the $Trainer.shadowcaught[species] array but I just can't figure out how.

    I want to make a Conditional branch where you fight a Trainer with a Shadow Pokémon and if you already caught the pokemon, be able to fight again against this trainer but without the Shadow Pokémon. Or even make a "Miror B" trainer like the Wiki page suggests but I don't know how to do this event either.

    I tried it like this:

    Conditional Branch > Script: $Trainer.shadowcaught[GEODUDE]
    -Fight Trainer without Shadow Geodude
    Else
    -Fight Trainer with Shadow Geodude
    End

    Or even like this:

    Script: $Trainer.shadowcaught[GEODUDE]=true
    Script: $Trainer.shadowcaught[074]
    Script: $Trainer.shadowcaught[species]=GEODUDE

    This should give you an idea of how lost I am.
     
    Firstly, $Trainer.shadowcaught[PBSpecies::GEODUDE]. Secondly, it is set to true automatically when capturing a Shadow Pokémon of that species. Thirdly, you're correct the first time with the Conditional Branch business.
     
    Oh, I would have never guessed I had to use "PBSpecies::" too. It works now. Thank you.
     
    Back
    Top