Typewritereffect that can change line?

hi there! I been searching a lot for a tut that shows u how to do the typewriter effect, but havent been able to find anything I can use.
I have a textfield and I want the effect as if the text is being written when it animates. The problem is that all the tutorials I have found about the typewriter effect, only displays a few words in one line… now, I need the same effect, only on a whole column and not just a single line. Is it even possible to do this? and if so, can someone guide me to a tutorial or help me out somehow?
thanks! :slight_smile:

TextField.prototype.typeWriter = function(cps) {
	var str = this.text, index = 0, field = this, typer = function () {
		index<=str.length ? field.text=str.substr(0, index++) : clearInterval(init);
	}, init = setInterval(typer, 1000/cps);
};

the argument cps, stands for characters per second, self explanatory i believe. :stuck_out_tongue:

just enter your text in a dynamic TextField, assign an instance name to the TextField and you’re all set. :wink:

myTextFieldInstanceName.typeWriter(12);

thanks a lot! Ill give it a try!

wohuuu! its working! no idear how it works, but it does!!!
thanks man!:stuck_out_tongue:

:stuck_out_tongue:

no problem, tsavo. :wink:

I ran into a small problem…
the textfield is placed inside a mc, that is placed inside of another mc… Now I cant get it to work.

I put your code in the mc containing the textbox and corrected the path to the textbox, but nothing happens now…:-\

hmm. just tried in a new document, and there it works just fine, without chaning anything… Don’t understand y i doesn’t work in the flash Im working with…

been experimenting a little, and found out that everytime I put the mc with the textfield on a layer, that is masked, it doesnt work… y is that?!!

in order to mask dynamic text, you must embed the font outline. :wink:

not sure how to do that…:q: :bounce:

anyways I found a way to work around it, but then - of course- a new prob occurd! when the clip begins, all is revealed in a glimpse before it begins! is there anyway to deal with this?:slight_smile:

Check This One Out

thx for all your help guys! it works perfectly now!!:stuck_out_tongue: