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

Temporarily disable the Trainer Card

129
Posts
14
Years
    • Seen Sep 4, 2023
    Hello,

    How should I go on temporarily disabling the Trainer card? Maybe making it unselectable in the start menu, appearing in grey color.
    I would like to control when the player receive his/her trainer card, and only then, be able to access it.

    Thank you!
     

    Nickalooose

    --------------------
    1,309
    Posts
    16
    Years
    • Seen Dec 28, 2023
    That's simple:
    Find this line:
    commands[cmdTrainer=commands.length]=$Trainer.name

    In: PokemonPauseMenu

    And add if $game_switches[x] to the end so it looks like this:
    Code:
    commands[cmdTrainer=commands.length]=$Trainer.name if $game_switches[x] # your switch number.
     
    94
    Posts
    11
    Years
    • Seen May 4, 2018
    In script PokemonPauseMenu, find this line:

    Code:
    commands[cmdTrainer=commands.length]=$Trainer.name

    add a condition like

    Code:
    commands[cmdTrainer=commands.length]=$Trainer.name [COLOR="Red"]if $game_switches[XXX]==true[/COLOR]

    XXX is the number of your switch. The game won't let you see the Trainer Card in the menu until you turn it on. I don't know how to make it both gray and unaccesible.

    I think I know how to make it unaccesible showing something like "???" instead of your name and when you select it you can make it display a message like "You don't have the Trainer Card yet". But it not being there makes more sense for me.

    EDIT: Whoops, I got ninja'd

    Ok, to make this post worthwhile, if you want to make what I mentioned above:

    Spoiler:
     
    Last edited:

    Nickalooose

    --------------------
    1,309
    Posts
    16
    Years
    • Seen Dec 28, 2023
    Spoiler:


    Sorry LenSho :P

    But editing this part:
    Code:
         elsif cmdTrainer>=0 && command==cmdTrainer
            PBDebug.logonerr {
               scene=PokemonTrainerCardScene.new
               screen=PokemonTrainerCard.new(scene)
               pbFadeOutIn(99999) { 
                  screen.pbStartScreen
                  @scene.pbRefresh
               }
            }
    Is all that would need to be edited really.
    Code:
          elsif cmdTrainer>=0 && command==cmdTrainer
            [COLOR="Red"]if $game_switches[x][/COLOR] # Your switch number
            PBDebug.logonerr {
               scene=PokemonTrainerCardScene.new
               screen=PokemonTrainerCard.new(scene)
               pbFadeOutIn(99999) { 
                  screen.pbStartScreen
                  @scene.pbRefresh
               }
            }
            [COLOR="red"]else
              Kernel.pbMessage(_INTL("You don't have a Trainer Card yet..."))
            end[/COLOR]
    This way saves creating unnecessary cmd functions anyway... As for changing the color, I can only assume there is no way when it comes to command lists.
     
    129
    Posts
    14
    Years
    • Seen Sep 4, 2023
    Thank you all very much! That was really helpful and the ninja thing was cool! :D
     
    Back
    Top