# Why does this script going slower and slower?

**URL:** https://forum.kirupa.com/t/why-does-this-script-going-slower-and-slower/217231
**Category:** flash
**Created:** [February 24, 2007, 4:30pm UTC](https://forum.kirupa.com/t/why-does-this-script-going-slower-and-slower/217231 "2007-02-24T16:30:59Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Macsy](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/macsy/32/3238_2.png) [@Macsy](https://forum.kirupa.com/u/Macsy)
#### Post date: [February 24, 2007, 4:30pm UTC](https://forum.kirupa.com/t/why-does-this-script-going-slower-and-slower/217231/1 "2007-02-24T16:30:59Z")

</div>

try this and give me response

```auto
var max:Number = 50;
var size:Number = Stage.width;
var step:Number = size/max;
var numb:Number = 0;
for (a=1; a<51; a++) {
    this.createEmptyMovieClip(["line"+a], 51-a);
    this["line"+a]._x = 250;
    this["line"+a]._y = 250;
    this["line"+a].lineStyle(1, 0x000000);
    this["line"+a].moveTo(a*step, -(a*step));
    this["line"+a].beginFill(Math.floor(Math.random()*999999 - 100000) - 100000)
    this["line"+a].lineTo(a*step, a*step);
    this["line"+a].lineTo(-(a*step), a*step);
    this["line"+a].lineTo(-(a*step), -(a*step));
    this["line"+a].lineTo(a*step, -(a*step));
    this["line"+a].endFill();
}
onEnterFrame = function () {
    if (numb == 50) {
        numb = 0;
    }
    numb += 1;
    this["line"+numb]._rotation += numb
    
    
};

```
