PDA

View Full Version : Follow mouse along X-cord



rowdy
May 7th, 2003, 01:21 AM
Does anyone know how to make a small graphic follow the mouse along a X-cord or a line.

a bonus would be for it to ease in and/or out.

If anyone knows how, or have an .fla example, me would be very happy.

Thanks.

Using Flash MX Actionscript

comicGeek
May 7th, 2003, 04:38 AM
Try searching the tutorials. I know that it's already there!

The basic script is

Flash 5:

onClipEvent(enterFrame){
_x += (_root._xmoouse - _x/3;
}


Try the tutorials, you'll learn faster there!