How to make the Text Automatically typing?

Hello,
i’m newbie here,i want to ask,how to make the text automatically typing when the layout is playing/started?
ex the text : “Hello,My name is Daniel.”

Thanks for your help

1 Like

What do you mean when you say “automatically typing?” Can you give more detail?

do you mean a text that appears letter by letter on the screen- like it does in jrpg games usually?

yess, you right ! :smiley:

hmm there are three ways I can think of that you can do this with:

First way:

Make your text box appear against a black background. Use Z-Order to make sure the text appears on top of the black box and that the black box appears over the top of your game (greatest Z-Orders show up on top). Then, make another black box on top of this text (one for each line of text). Make sure that has a greater Z-Order than the text object. Make this black box scroll to the right (increasing x) in increments which are the size of one character of text. I’m not sure how good this will look (probably alright if you time the scroll well), but it’s quite quick and easy to set up.

Second way:

Have every letter in a separate text box, all lined up together and reveal them one by one with a timer. This will probably look better, but will take absolutely ages to set up. Not recommended.

Third way:
Make the text animation in another program and export it as frames. Then make a sprite in GameDevelop and add these animation frames to it and then make the animation, using a timer to go through the frames of the animation at appropriate speed. Probably the best way to go.

hmm… okay,because i’m newbie here,i’m not understand :blush:

Check this out:
Autotyping.rar (1.54 KB)

First I set a variable String = the text you want and set the Text Object’s text = “” [size=85](this is an empty string)[/size]
Then use a timer to (every 0.2 seconds) add 1 in a variable StringSize and change the Text Object’s text = portion of String variable from letter 0 to letter = StringSize

Every 0.2 seconds StringSize is bigger, then the portion of text shown is bigger :slight_smile:

1 Like

Great solution Lizard (as always)!

Thanks! Of course needs to be “polished”… for example could be added a condition to check if the portion size is bigger than the entire text, otherway the text portion will be increased indefinitely :neutral_face:

1 Like

its been 4 yrs, and i just wanna say that there is a autotype behavour in GD now, so…

1 Like