# onEnterFrame

**URL:** <https://forum.kirupa.com/t/onenterframe/222127>\
**Category:** Uncategorized\
**Created:** [April 11, 2007, 2:58am UTC](https://forum.kirupa.com/t/onenterframe/222127 "2007-04-11T02:58:47Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Denise032](https://avatars.discourse-cdn.com/v4/letter/d/9e8a1a/32.png) [@Denise032](https://forum.kirupa.com/u/Denise032)\
**Post date:** [April 11, 2007, 2:58am UTC](https://forum.kirupa.com/t/onenterframe/222127/1 "2007-04-11T02:58:47Z")

</div>

I’ve searched and searched for this, but couldn’t find it… I have the following code (thanks to a post from a few years ago on here),

```auto
MovieClip.prototype.Increment = function(maxAlpha, speed) {
this.onEnterFrame = function() {
this._alpha += speed;
if (this._alpha>=maxAlpha) {
this._alpha = maxAlpha;
delete this.onEnterFrame;
}
};
};
with (clip) {
_alpha = 0;
Increment(100,4);
}

```

but I have a question…

What I want to do is fade in a MC, then say 5 seconds later, fade in another, and then another 5 seconds after THAT, fade in a third, so on…Can anyone tell me how to achieve this w/ AS?

PS-I know how to do it w/ motion tweens, but I really would like to do this w/ AS.
