SpriteFont Color

  • Hey guys,

    I'm really surprised I didnt find a thread talking about coloring SpriteFonts.

    Isn't there any possibility/plugin to color a SpriteFont during runtime?

    It can't be a solution to have serveral different coloured spritefonts just to change color.

    Thanks in advance,

    Vuuv

  • you could use the set colour effect

  • quick example

  • Wouldnt this affect the performance in a bad way?

  • I tried to change the colour with the effect and it works. But fps go down for 10...

    (on my phone its even a 20 fps drop)

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • I suggest you take that SpriteFont file to your favorite image editor and set it to all the different colors you wish to use, to get as many SpriteFont files as colors you want, then add them all to the project, each one with the name of the color. (As you can't add animations to SpriteFonts unfortunately, which would make things easier).

    That way you won't have to use effects and impact your game performances. Only the memory used.

  • SpriteFont is SPRITE first font second. They are at their core a Sprite. When you need the font in another style you need a Sprite to match.

    Do a forum search for

    GiveYourFontsMono

  • I already use GiveYourFontsMono. I just wanted to avoid Telyko's solution... thought maybe there would be a a beautiful solution for this problem.

  • Could try using the tint/change colour effects, and then pasting the resulting image to a PASTER object. This makes it so the effect is only applied for a single tick and the result is saved on a PASTER object.

  • Sorry for bringing this up, but I wanted to ask... is there a reason we can't simply add in another sprite sheet or frame to the SpriteFont to use in order to change colour?

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)