Plugins: show text by sprites

0 favourites
From the Asset Store
OpenAI TTS
$10 USD
Text-to-Speech plugin.Allows your Construct 3 project to convert written text into spoken words
  • rexrainbow

    Yeah, set all sprites of a layouter object to invisible / hidden. Destroy will 'destroy' the object, so that is no good (as you know), and the Create / Remove instances seem better suited for multiple creations of a layouter.

    In my case, I just want to display text, and then hide it later. Basically I am using layouter in place of spritefont.

  • rexrainbow

    Sorry to bother you more, but right now you have to write a function to resize a sprite (as seen in your text example). Is there a way that the layouter could have a command to scale all associated sprites that are a part of it? This would make scaling text and such much easier than writing a function to do so.

    I am currently setting all the text to "" to hide them (essentially blank). Is this a sufficient practice? This is needed since the layouters I am using are global and used in a end level score card.

  • Zharzew

    Okay, I will add action to set visible , opacity to all sprites.

    The scale changing only set the scale of each sprite, not the spacing. Is it ok?

  • rexrainbow

    Is it possible to align the text using an image point? I am noticing that it aligns to whatever edge you have selected (ie left). I am just trying to center some text and it is aligning just off center, because of this.

    Thanks for any help! This thing is awesome! :)

    I am not sure, do you want to alignment text to a target position? You might set the position of layouter object first, then set text.

  • rexrainbow

    Scaling the sprite, but leaving the spacing between them should work great! :)

    As for the alignment or the sprite, I am already aligning the layouter object to be center, it is the collected sprites that is not centering (they are just off center, it is really weird). It easiest to see when there is just one sprite that draws, multiple sprites (ie 2 or more) seem to center much better. When just one is there, it appears that it is aligning the 'left side of the sprite' to the center (of the layouter), not the 'center of the sprite'. I hope that makes sense.

    I guess I was thinking if we could have the sprite align to the origin point (or any image point) it would be easier to do just that (basically just put the image point at the center of your sprite). This could open up all sorts of neat alignment tricks potentially.

    Thanks again! You are too awesome! This plugin is just great, just like all your other work! :)

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Zharzew

    Thanks, I will fix the mis-alignment of center mode.

  • Update:

    Now designer could change all characters opacity , visible from "action: set opacity" , "action: set visible" of layouter object. Or add sine/tween behavior at layouter object to change these properties.

    There already has a "pin mode" which could pin all characters onto layouter object. So that all characters could be moved with layouter object.

  • California

    I agree, delta distance is not a suitable name in this case. I will try to fix it. Tracing is a great option. Or... Spacing?slg@rexrainbow spacing is more often used in line spacing (also called leading):

    <img src="http://www.webcomicalliance.com/wp-content/uploads/2011/01/fontfactor-tracking.jpg" border="0" />

    webcomicalliance.com/wp-content/uploads/2011/01/fontfactor-tracking.jpg

    <img src="http://netdna.webdesignerdepot.com/uploads/small_caps//tracking-vs-leading.png" border="0" />

    netdna.webdesignerdepot.com/uploads/small_caps//tracking-vs-leading.png

  • California

    Thanks, one question:

    "Tracing" seems to be a length (width) of some characters, is it the same for one character?

  • rexrainbow

    This is great plugin! Thanks rexrainbow.

    But I find this plugin show font by creat instance of every character. This may lead low performance on moblie.

    Is there some way to optimize it?

  • California

    Thanks, one question:

    "Tracing" seems to be a length (width) of some characters, is it the same for one character?

    rexrainbow Tracking defines the same spacing for all the characters.

    Kerning defines the spacing between two characters.

    Any questions just ask :)

  • Nofish

    Yes, these plugins will create sprites for each character. Designer could control them in event sheet.

    Another choice, using sprite font plugin. It creates all characters in one instance.

  • California

    Tracing = Character width + Kerning

    Is it true?

  • rexrainbow nope, tracking (with a ck) adjusts spacing evenly over a range of characters, i.e. a paragraph.

    Tracking = Width of all the characters in a paragraph, applies to all the characters.

    Kerning OTOH is the spacing between Only Two characters, it's usually defined by hand (or by auto-kerning) so spacing between letters like "A V" looks more pleasing:

    AV (observe how the V overlaps over the letter A).

    Without kerning, AV would look like this: A V.

  • Just to explain better what California is trying to say, 'tracking' is the spacing between the characters, where the same amount of space is added between all characters, including spaces. It's the '_' in this example:

    T_h_i_s_ _is_ _t_r_a_c_k_i_n_g_.

    Kerning is the space between pre-defined character pairs. It's meant to compensate the geometry of characters like 'A' and 'V' together. If you align them by their bounding box the space between their oblique shapes will be perceived as larger than strait characters like 'N' and 'H'. So in a font they specify that some pairs of characters overlap their bounding box by some pre-defined amount in order to compensate visually.

    But I don't think that Kerning is absolutely necessary for this plugin, and probably would be extremely hard to implement. Having characters with variable width can be enough to avoid that 'l' have a bigger space around than an 'M' for instance.

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