Generating Text that looks like it's being typed in real time..

Greetings all,

I’m trying to make text that prints out on screen letter by letter… like it looks someone is typing it in real time.   Instead of having a block of text show up, I want it to slowly look like each letter is being typed.

How to achieve this?  Sorry if this already been asked or in an obvious tutorial, I’ve looked around and couldn’t find it-

Thanks!

Create a display group that will hold all of the individual letters, as individual images.

Create a function that is repeat every 200 milliseconds.

Inside the function do this:

  • Read out the ascii value of the first letter of the text

  • place a corresponding image from a spritesheet in the group (a = image1, b  = image2 etc…) with x = 0

  • add +1 to a counter variable

  • read out the next letter from a string of text using the counter value, with the x position set to counter * horizontal spacing

  • do a check to see if this is the last letter of the string. If so, cancel the repeating function

Create a display group that will hold all of the individual letters, as individual images.

Create a function that is repeat every 200 milliseconds.

Inside the function do this:

  • Read out the ascii value of the first letter of the text

  • place a corresponding image from a spritesheet in the group (a = image1, b  = image2 etc…) with x = 0

  • add +1 to a counter variable

  • read out the next letter from a string of text using the counter value, with the x position set to counter * horizontal spacing

  • do a check to see if this is the last letter of the string. If so, cancel the repeating function