• 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!
  • Which Pokémon Masters protagonist do you like most? Let us know by casting a vote in our Masters favorite protagonist poll here!
  • Red, Hilda, Paxton, or Kellyn - which Pokémon protagonist is your favorite? Let us know by voting in our poll!
  • 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] Essentials 1.18.1 - Color text in scripts

  • 15
    Posts
    4
    Years
    • Seen Dec 15, 2021
    I will be quick and concise.

    They will see. Thanks to someone who commented on my previous post I have managed to show options with a script, but I would like to take it further. I would like to use the text formats in this script. I would like the word "Access" to look as usual in "Access PC", but "PC" is colored and bold. I have tried as in normal text, but it does not work.

    Can you help me?
     
    Currently, seeing the way it is coded, what you ask is not possible.

    You are refering to the following function:
    Code:
    def pbMessage(message,commands=nil,cmdIfCancel=0,skin=nil,defaultCmd=0,&block)
    and if you look at its code, you'll find that the first argument message is handled by pbMessageDisplay, which is the only function (as far as I can tell) that actually processes formatting (which is why formatting works in messages).

    What you'll also find, if you dig into the code, is that commands are displayed by:
    Code:
    def pbDrawShadowText(bitmap,x,y,width,height,string,baseColor,shadowColor=nil,align=0)
    that displays one item with the baseColor given (which is default in Window_CommandPokemonEx, and anyways you want to change color in the middle of the command).

    What you ask requires modifying pbDrawShadowText to make it process the formatting like pbMessageDisplay does.
    Unless you know what you're doing, maybe consider it impossible.
     
    Last edited:
    Theres a script on relic castle by maruno that does that. I cant find it now but if you do a bit of digging you should find it

    Are you refering to (broken link removed)?
    If yes, it has been integrated to Esssentials ^^"
     
    Back
    Top