# Mouse trail

**URL:** <https://forum.kirupa.com/t/mouse-trail/41725>\
**Category:** Uncategorized\
**Created:** [February 1, 2004, 8:53am UTC](https://forum.kirupa.com/t/mouse-trail/41725 "2004-02-01T08:53:37Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![UnblessedOmega](https://avatars.discourse-cdn.com/v4/letter/u/8edcca/32.png) [@UnblessedOmega](https://forum.kirupa.com/u/UnblessedOmega)\
**Post date:** [February 1, 2004, 8:53am UTC](https://forum.kirupa.com/t/mouse-trail/41725/1 "2004-02-01T08:53:37Z")

</div>

hello…does anyone know how to change the color of the text following the mouse?

Text = “Kirupa has the best site on the net!!!”;  
letters = Text.split("");  
letterformat = new TextFormat();  
letterformat.font = “Verdana”;  
letterformat.align = “center”;  
letterformat.size = “10”;  
spacing = 8;  
speed = 3;  
for (var LTR = 0; LTR\<letters.length; LTR++) {  
mc = \_root.createEmptyMovieClip(LTR+“l”, LTR);  
mc.createTextField(letters[LTR]+“t”, LTR, LTR\*spacing, 10, 20, 20);  
with (mc[letters[LTR]+“t”]) {  
text = letters[LTR];  
setTextFormat(letterformat);  
selectable = false;  
}  
if (LTR) {  
mc.prevClip = \_root[(LTR-1)+“l”];  
mc.onEnterFrame = function() {  
this.\_x += (this.prevClip.\_x-this.\_x+5)/speed;  
this.\_y += (this.prevClip.\_y-this.\_y)/speed;  
};  
} else {  
mc.onEnterFrame = function() {  
this.\_x += (\_root.\_xmouse-this.\_x+10)/speed;  
this.\_y += (\_root.\_ymouse-this.\_y)/speed;  
};  
}  
}
