• 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 Trading Card Game 2 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.

[Custom Feature Question] help with healing all pokemon in pc

  • 16
    Posts
    12
    Years
    • Seen Apr 25, 2020
    i want to create a storage system similar to the lets go games where you can access your storage from anywhere in the game. i have successfully added the option of accessing storage from the pause menu, as well as disabled pokemon being healed when deposited. what im looking for is a way to heal all pokemon in storage when visiting a pokecenter. help with this would be much appreciated!
     
    Do you know where the Pokécenter heal script is? Should be easy enough to alter it so that in addition to healing the party it also loops over all the Pokémon in the PC and heals those too. What part are you having trouble with?
     
    Do you know where the Pokécenter heal script is? Should be easy enough to alter it so that in addition to healing the party it also loops over all the Pokémon in the PC and heals those too. What part are you having trouble with?
    the problem with the pokecenter script is it uses the event command "recover all..." and from there you can only choose entire party or player, and both just heal the party. i also found this script that again just heals the whole party:

    for i in $Trainer.party
    i.heal
    end

    i thought this might be a good starting point but no luck
     
    the problem with the pokecenter script is it uses the event command "recover all..." and from there you can only choose entire party or player, and both just heal the party.
    Yeah, so my suggestion was to find that script in the Essentials code and modify it to loop over the Pokémon in storage...

    i also found this script that again just heals the whole party:

    Code:
    for i in $Trainer.party
      i.heal
    end

    i thought this might be a good starting point but no luck
    ... And that does look like a good starting point. But instead of looping over $Trainer.party you need to (additionally) loop over the Pokémon in $PokemonStorage, which you'll probably have to do by looping over the boxes in the storage, and then over each Pokémon in those boxes.
     
    Last edited:
    where would i find that at? i searched through the scripts but not exactly sure what im looking for

    I don't know. Try searching all files (Ctrl+Shift+F) for ".heal" and work your way through until you find something that looks like the code for healing the party (i.e. similar to the code you posted earlier).

    Or you could try looking on the Essentials wiki for the name of the function to call from an event to heal the party, and see if you can find it by searching for "def name-of-function".
     
    Last edited:
    Back
    Top