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

[Eventing Question] Remove all Pokémon from party

  • 7
    Posts
    6
    Years
    • Seen Dec 12, 2018
    Hello guys!

    I'm trying to make an event in which I receive a Pokémon to catch another 3... After that, I want to remove all of them from the party (so I'll have no Pokémon left).

    Does anyone know a way to do it?
     
    The script $Trainer.party.delete_at(index), where "index" is the spot in the player's party, will let you delete even the player's last able pok?mon.
    You could set up the script as:
    Code:
    for i in 0...$Trainer.party.length
         $Trainer.party.delete_at(i)
    That should do it.
     
    Last edited:
    The script $Trainer.party.delete_at(index), where "index" is the spot in the player's party, will let you delete even the player's last able pok?mon.
    You could set up the script as:
    Code:
    for i in 0...$Trainer.party.length
         $Trainer.party.delete_at(i)
    That should do it.

    Basically, I'll have to create a new script line on the script section and put the code, than I'd have to to call it on the event?
    I'm not so good at scripting so, I don't know if I got it right.
    if you could send my pictures, it'd help me a lot!
     
    Basically, I'll have to create a new script line on the script section and put the code, than I'd have to to call it on the event?

    No, you can use the script I just wrote in the event. If you haven't added a script like to an event before, it's the very last option on the third tab.
     
    No, you can use the script I just wrote in the event. If you haven't added a script like to an event before, it's the very last option on the third tab.

    Thanks for the help! It's working great.
    xD
     
    • Like
    Reactions: Poq
    Back
    Top