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

[Scripting Question] Access Pokemon Storage Boxes from the pause menu (Let's Go Style)

  • 16
    Posts
    12
    Years
    • Seen Apr 25, 2020
    If you have played either of the Let's Go games for Switch, you know what I'm talking about. If you haven't, Let's Go made a big change to how you can access the Pokemon you have caught. Instead of using PCs in PokeCenters to access your storage boxes, you can now access your storage from virtually anywhere and swap Pokemon in and out of your party at any time. I for one absolutley loved this change and wanted to incorporate it into my own game. With much assistance from Wonsul and MGriffen from the following forum ((broken link removed)) and my very little knowledge with scripting, I have nearly successfully replicated this in Essentials 17.2.

    They only hangup I have run into is that in Essentials, when you deposit a Pokemon into storage it fully heals it. With the ability to access your Pokemon storage from anywhere, this would basically break the game as you could just deposit a damaged or fainted Pokemon to restore it to full health at any point. In Let's Go the Pokemon are not healed upon storing them and are instead healed alongside your party when you visit a PokeCenter. Again, with help from the forum shared above, I managed to stop Pokmon from being healed when moving them manually into storage. I was not able to figure out how to prevent healing when using the "Deposit" option, so I just decided to remove the "Withdraw" and "Deposit" options all together.

    What I need assistance with, is I need a way to make the game heal not just the Pokemon in my party when I visit a PokeCenter, but heal all Pokemon in storage as well. I have tried a bunch of little things with no luck. Like I said my knowledge of scripting is very limited. I have attached step-by-step everything I have done up to this point. Feel free to use, I don't need credit but you may want to credit Wonsul and MGriffen, as most of this is from them.

    Adding "Storage" access to the Pause Menu:
    Locate script section "PScreen_PauseMenu" and look for:
    PHP:
    def pbStartPokemonMenu
        pbSetViableDexes
        @scene.pbStartScene
        endscene = true
        commands = []
        cmdPokedex  = -1
        cmdPokemon  = -1
        cmdBag      = -1
        cmdTrainer  = -1
        cmdSave     = -1
        cmdOption   = -1
        cmdPokegear = -1
        cmdDebug    = -1
        cmdQuit     = -1
        cmdEndGame  = -1

    This is the order in which these options appear in the pause menu. Add "Storage = -1" where ever you want it to appear in game. I added mine between Pokemon and Bag.
    PHP:
    def pbStartPokemonMenu
        pbSetViableDexes
        @scene.pbStartScene
        endscene = true
        commands = []
        cmdPokedex  = -1
        cmdPokemon  = -1
        cmdStorage  = -1
        cmdBag      = -1
        cmdTrainer  = -1
        cmdSave     = -1
        cmdOption   = -1
        cmdPokegear = -1
        cmdDebug    = -1
        cmdQuit     = -1
        cmdEndGame  = -1

    A few lines below look for:
    PHP:
    commands[cmdPokedex = commands.length]  = _INTL("Pokédex") if $Trainer.pokedex && $PokemonGlobal.pokedexViable.length>0
     commands[cmdPokemon = commands.length]  = _INTL("Party") if $Trainer.party.length>0
     commands[cmdBag = commands.length]      = _INTL("Bag") if !pbInBugContest?
     commands[cmdPokegear = commands.length] = _INTL("Pokégear") if $Trainer.pokegear
     commands[cmdTrainer = commands.length]  = $Trainer.name

    Add the line "commands[cmdStorage = commands.length] = _INTL("Storage")" somwhere in here. I placed it between Pokemon and Bag once again.
    PHP:
    commands[cmdPokedex = commands.length]  = _INTL("Pokédex") if $Trainer.pokedex && $PokemonGlobal.pokedexViable.length>0
     commands[cmdPokemon = commands.length]  = _INTL("Pokémon") if $Trainer.party.length>0
     commands[cmdStorage = commands.length]  = _INTL("Storage")
     commands[cmdBag = commands.length]      = _INTL("Bag") if !pbInBugContest?
     commands[cmdPokegear = commands.length] = _INTL("Pokégear") if $Trainer.pokegear
     commands[cmdTrainer = commands.length]  = $Trainer.name

    Further down, locate the folowing scripts:
    PHP:
          elsif cmdBag>=0 && command==cmdBag
            item = 0
            pbFadeOutIn(99999){ 
              scene = PokemonBag_Scene.new
              screen = PokemonBagScreen.new(scene,$PokemonBag)
              item = screen.pbStartScreen 
              (item>0) ? @scene.pbEndScene : @scene.pbRefresh
            }
            if item>0
              Kernel.pbUseKeyItemInField(item)
              return
            end
          elsif cmdPokegear>=0 && command==cmdPokegear
            pbFadeOutIn(99999){

    Below "end" and before "elsif cmdPokegear" add the following:
    PHP:
          elsif cmdStorage>=0 && command==cmdStorage
            pbFadeOutIn(99999){
            scene = PokemonStorageScene.new
            screen = PokemonStorageScreen.new(scene,$PokemonStorage)
            screen.pbStartScreen(0)
          }

    It should now look like this:
    PHP:
          elsif cmdBag>=0 && command==cmdBag
            item = 0
            pbFadeOutIn(99999){ 
              scene = PokemonBag_Scene.new
              screen = PokemonBagScreen.new(scene,$PokemonBag)
              item = screen.pbStartScreen 
              (item>0) ? @scene.pbEndScene : @scene.pbRefresh
            }
            if item>0
              Kernel.pbUseKeyItemInField(item)
              return
            end
          elsif cmdStorage>=0 && command==cmdStorage #add this line
            pbFadeOutIn(99999){
            scene = PokemonStorageScene.new
            screen = PokemonStorageScreen.new(scene,$PokemonStorage)
            screen.pbStartScreen(0)
          }
          elsif cmdPokegear>=0 && command==cmdPokegear
            pbFadeOutIn(99999){

    If done correctly you should now be able to directly access the Pokemon Storage Boxes from the pause menu!

    Disable healing when placing Pokemon in storage:
    Refer to McGriffen's post about 1/3 the way down the following page ((broken link removed)).

    Remove Withdraw and Deposit options from Pokemon Storage screen:
    Locate the following in script section PScreen_PC:
    PHP:
      def access(is_pc)
    	Kernel.pbMessage(_INTL("\\se[PC access]The Pokémon Storage System was opened."))
    	loop do
    	  command=Kernel.pbShowCommandsWithHelp(nil,
    		 [_INTL("Organize Boxes"),
    		 _INTL("Withdraw Pokémon"),
    		 _INTL("Deposit Pokémon"),
    		 _INTL("See ya!")],
    		 [_INTL("Organize the Pokémon in Boxes and in your party."),
    		 _INTL("Move Pokémon stored in Boxes to your party."),
    		 _INTL("Store Pokémon in your party in Boxes."),
    		 _INTL("Return to the previous menu.")],-1
    	  )

    Remove the lines _INTL("Withdraw Pokémon"),, _INTL("Deposit Pokémon"),, _INTL("Move Pokémon stored in Boxes to your party."),, _INTL("Store Pokémon in your party in Boxes."),

    It should now look like this:
    PHP:
      def access(is_pc)
        Kernel.pbMessage(_INTL("\\se[PC access]The Pokémon Storage System was opened."))
        loop do
          command=Kernel.pbShowCommandsWithHelp(nil,
             [_INTL("Organize Boxes"),
             _INTL("See ya!")],
             [_INTL("Organize the Pokémon in Boxes and in your party."),
             _INTL("Return to the previous menu.")],-1
          )

    And that is everything I have so far. Again, all I need now is a way to heal all Pokemon in storage when visiting a PokeCenter. Any assistance would be greatly appreciated!
     
    Um, problem, I'm using it with MODMN, and PokemonStorage_Scene part of the code just gives an error. I'm adapting it to v18.1. I believe you forgot about the lines of code in Scene_Commands
     
    Last edited:
    You'd want to use something like below to heal party.
    Code:
    $Trainer.party.each { |pkmn| pkmn.heal }

    One way to heal all 'storage' is to have to link those pokemon to local variable array, and then run the same |pkmn| pkmn.heal using that array instead of $Trainer.party array.

    examplearray.each

    then you can just search where the PKMN center theme song play, and at that location, also puts in your heal code to run at the same time that BGM plays.
     
    Last edited:
    Um, problem, it's not PokemonStorage_Scene it's PokemonStorageScene you may want to fix that
    It depends on the version. In v17.2 it's PokemonStorage_Scene but in v18 it's PokemonStorageScene.
     
    This thread is over two years old and the OP hasn't been active in nearly a year, so I don't know why you'd expect it to have been updated for v18. It also clearly states that this was for v17.2 at the end of the first paragraph. I guess reading is overrated these days.
     
    Back
    Top