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

[Scripting Question] Give Pokedex upon win

63
Posts
16
Years
  • I am trying to give the player a Pokedex when they beat a trainer. It works, however it works even when the player loses. You receive the Pokedex even after you lose and black out. How do I change it to only give you the Pokedex/any item upon winning only? Thanks!
     
    19
    Posts
    4
    Years
    • Seen Jan 14, 2021
    I'm assuming this is done via an event. Can you show us the code? Make sure that the code that give the player the pokedex is only being fired "On win" - you should have a conditional branch to call the battle for that.
     
    Back
    Top