Frame 1
function line(x1, y1, x2, y2) {
mc_line = this.createEmptyMovieClip("mc" + count, ++count);
if (count > ((len * len) - 1)) {
count = 0;
}
mc_line.lineStyle(6, 16711680);
mc_line.moveTo(x1, y1);
mc_line.lineTo(x2, y2);
}
_root.onLoad = function () {
friction = 0.96;
len = 50;
xpos = new Array(len);
ypos = new Array(len);
xspeed = new Array(len);
yspeed = new Array(len);
i = 0;
while (i < len) {
xpos[i] = (Stage.width / 2) + i;
ypos[i] = (Stage.height / 2) + i;
xspeed[i] = 0;
yspeed[i] = 0;
i++;
}
count = 0;
};
_root.onEnterFrame = function () {
i = 0;
while (i < len) {
yspeed[i] = yspeed[i] + ((ypos[i] - _ymouse) / (200 - i));
xspeed[i] = xspeed[i] + ((_xmouse - xpos[i]) / (200 - i));
xspeed[i] = xspeed[i] * friction;
yspeed[i] = yspeed[i] * friction;
line(xpos[i], ypos[i], xpos[i] + xspeed[i], ypos[i] - yspeed[i], count);
xpos[i] = xpos[i] + xspeed[i];
ypos[i] = ypos[i] - yspeed[i];
i++;
}
};