Is it possible to change SpriteFont: Image, and Character Set, on the fly?

0 favourites
  • 3 posts
From the Asset Store
Simplistic hyper-casual game with nature elements. Tap to switch between the 4 elements and reach a better score.
  • Hey all,

    First off, apologies if this is answered elsewhere... I've been searching for a while now and haven't found anything.

    My question is:

    Is it possible to set a new SpriteFont Image and accompanying Character Set on the fly?

    The goal is for me to swap out different alphabets based on user-selected languages. The text content swaps out fine of course, but I'd really rather not have to have a new SpriteFont in the game for every different alphabet I may end up needing access to. Granted, I'm a long way off of any language other than English being used, but I'd like to build in this kind of accessibilty potential at the beginning, rather than later... So if its not possible out of the box, is it something I can tinker with in the plugin's code? I'm happy to make a duplicate plugin and play around with it, I just thought I'd ask first.

    Thanks in advance,

    Brent

  • I feel like using sprite fonts is not standard practice for games that support multiple languages.

    The obvious example is Chinese, where sprite fonts are mostly unfeasible to begin with. I'd stick with the text object for multi language support, or use dedicated sprite fonts for each language you want to support. It would be more work and you'd probably end up supporting just a few select languages.

    Put the sprite font objects in a family, and use functions with language parameter to manage them.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • That's my current workaround, it mostly just seems like an odd limitation in the SpriteFont object. The Text object is undesirable as I do all my games at 240p and most webfonts just don't look good at that size. I prefer to stylize and design my own fonts around the specific game anyway (in combination with a "system font" that I use in everything). I'm curious if the functionality is possible, even if the use may be impractical...

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