Updating to flash 5 syntax

Hey people,

I’m currently working off of some free source material, and I was having some trouble with it. First of all here’s the code that resides in the _root of the movie:

In frame 1:

text = “Test text”;
i = 1;
max = length(text);
kerning = “10”;
size = “10”;
setProperty (“char”, _visible, “0”);

In frame 7:

duplicateMovieClip (“char”, “char” add i, i);
set ("/char" add i add “/letter:char”, substring(text, i, 1));
setProperty ("/char" add i, _x, 100+Number(ikerning));
setProperty ("/char" add i, _xscale, 10
size);
setProperty ("/char" add i, _yscale, 10*size);
i = Number(i)+1;

In frame 8:

if (Number(i)>Number(max)) {
stop ();
} else {
gotoAndPlay (3);
}

This is basically one of those text effects which are rather common. The reason I was going to use this method was because once I get it working, I can just change the text I want for any subsequent animation, and if I ever has to expand my project, it won’t be all that hard. This code is going to be placed in a movieclip I named teffect. I never really used Flash 4, and wasn’t sure if /char means _root.char, and /letter:char means _root.letter.char ?

So my question boils down to: if I wanted to place this same code in a movieclip named teffect which sat in the root of my movie (_root.teffect), how would I update it properly for location (incase I’m doing that wrong) and syntax?

Thanks for any help,

Uth

It’s been a while since I used F4 but from what I remember

/ references root i.e: /MC=_root.MC
./ references _parent i.e: ./MC=_parent.MC
…/references _parent._parent i.e: …/MC=_parent._parent.MC

the : refers to a variable

so /MC:var = _root.MC.var