SpriteFont - Text append limit on vertical align?

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

    I'm trying to create a text-based console interface using the SpriteFont-object in Construct 2, but it seems to me that it's impossible to append text to the object if the textbox is already completely filled up?

    Furthermore, there doesn't appear to be any way to count the number of lines in a text string so that you can remove the top line?

    Anyone know how I could get around this issue?

  • Put newline at end of text that you are appending.

    Count newlines.

    Textbox don't fill up they just don't scroll down to last entry.

    See this topic, I've been overcomplicating something similiar.

    Newest entry first

  • Well, even if you are able to count newlines there still doesn't seem to be a way to remove the top line, or is there?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Yes you can remove top line,

    Store total line numbers tokencount(text.text,newline) to a variable linenumbers

    I would use system:repeat x: x being tokencount(text.text,newline)

    Append text to a textbox line by line ->

    Textbox.text : Append : tokenat(text.text,linenumbers,newline)

    subtract 1 from variable linenumbers

    Well something like that.

    Warning! I tend to overcomplicate things sometimes. There may be simple way, just my brain isn't picking it up right now.

    Okay did this quickly: Very very raw, but proves it can be done :)

    Small demo

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