Leaves v1…
After searching the net for a few hours looking for a script that similates this, i found nothing… so i started creating my own… after a few hours of fiddeling i made this…
// Leaves v1 2005 by sWo0p //
onClipEvent (load) {
a = 0;
i = 0;
xMove = random (10) + 5; // Horizontal wind speed..
yMove = random (70) + 5; // Horizontal wind speed..
if (_name == "leaves")
{
_visible = false;
}
}
onClipEvent (enterFrame) {
if (_name != "leaves")
{
_y = Math.sin (a) * yMove + 50;
_x += Math.sin (a) * xMove + 3; // Set to 0 and it becomes a "Tornado"..
a += 0.09;
if (this._x > 300) // Horizontal distance they trafel..
{
if (this._alpha > 1) {
this._alpha = this._alpha - 0.5; // Fading factor of the leaves..
} else {
this.removeMovieClip ();
}
}
}
else
{
if (random (5) == 1 ) { // Random delay "(5) =="..
++i;
duplicateMovieClip (this, "leaf" + i, i);
if (i == 100)
{
i = 10;
}
size = random (40) / 40; // Leaves size, keep it even..
_parent["leaf" + i]._width *= size;
_parent["leaf" + i]._height *= size;
}
}
}
// The End //
its simple create a movieclip, give it an instance “leaves”, press F9 and paste the action script above on the movieclip…
let me know what you think of it… and if you added anything let us know…