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

pbEnterNPCName?

Cilerba

the hearts of lonely people
1,162
Posts
14
Years
  • The wiki doesn't have much documentation (or any, for that matter) on pbEnterNPCName and I can't seem to figure out how it works by looking through the scripts. Can anybody elaborate on how to properly use this?
     

    Maruno

    Lead Dev of Pokémon Essentials
    5,286
    Posts
    16
    Years
    • Seen May 3, 2024
    Code:
    pbSet(42,pbEnterNPCName(
       "Rival's name?",1,7,"Blue","trchar004")
    )
    It works just like pbEnterText, but with an extra parameter on the end, which is the name of the NPC's charset file in the folder Graphics/Characters. It will return the name entered, which you have to store in a variable or do whatever you want with it.

    The example asks the player to name the rival, accepting any name between 1 and 7 characters long, with a default name of Blue already input. The image of the rival used is the file Graphics/Characters/trchar004.png. The name is stored in game variable 42 by the method pbSet.
     

    Zeak6464

    Zeak #3205 - Discord
    1,101
    Posts
    11
    Years
  • Code:
    pbSet(42,pbEnterNPCName(
       "Rival's name?",1,7,"Blue","trchar004")
    )
    It works just like pbEnterText, but with an extra parameter on the end, which is the name of the NPC's charset file in the folder Graphics/Characters. It will return the name entered, which you have to store in a variable or do whatever you want with it.

    The example asks the player to name the rival, accepting any name between 1 and 7 characters long, with a default name of Blue already input. The image of the rival used is the file Graphics/Characters/trchar004.png. The name is stored in game variable 42 by the method pbSet.

    issue , the image for the character isn't showing up
    screenshot_280.png

    screenshot_281.png
     

    Luka S.J.

    Jealous Croatian
    1,270
    Posts
    15
    Years
  • issue (that's your problem, not Maruno's), the image for the character isn't showing up

    How about using the methods that you're supposed to use in the BW kit? It isn't stock Essentials.

    P.S. You're not even using the same function that is being discussed here...
     
    Last edited:
    Back
    Top