# setInterval Question

**URL:** <https://forum.kirupa.com/t/setinterval-question/220052>\
**Category:** flash\
**Created:** [March 22, 2007, 5:18am UTC](https://forum.kirupa.com/t/setinterval-question/220052 "2007-03-22T05:18:33Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![deltajam](https://avatars.discourse-cdn.com/v4/letter/d/7993a0/32.png) [@deltajam](https://forum.kirupa.com/u/deltajam)\
**Post date:** [March 22, 2007, 5:18am UTC](https://forum.kirupa.com/t/setinterval-question/220052/1 "2007-03-22T05:18:33Z")

</div>

Just trying to use setInterval in a class … 🙂 mmmm… 🅰

I can’t seem to get my params passed through though.

Here is the main .fla file calling the class:

```auto

 var clips:Initialize = new Initialize(this); 
 clips.init("title", o, alphaBlur, 1000, 14, 12, 81);

```

And here is the class (thus far):

```auto

import as.classes.Transition;
class as.classes.Initialize {
 private var clip:MovieClip;
 private var time:Number;
 private var xPos:Number;
 private var yPos:Number;
 private var t:MovieClip;
 private var trans:Function;
 public var onStage:Array;
 private var intervalId:Number;
 private var appear:Function;
 function Initialize(mc:MovieClip) {
  t = mc;
  onStage = new Array();
 }
 public function init(mc:String, o:Object, trans:Array, time:Number, alpha:Number, xPos:Number, yPos:Number) {
   var clip:MovieClip = t.attachMovie(mc, mc, t.getNextHighestDepth(), {_alpha:alpha, _x:xPos, _y:yPos});
   var effect:Transition = new Transition();
   for (var i = 0; i<trans.length; ++i) {
    effect[trans*.func](clip, trans*, alpha);
   }
   onStage.push(clip);
 }
}

```

ok … everything works **without** the setInterval. However when I pass the ‘time’ param through to the init method, I would like the clip to come in at the that time. So right now the ‘title’ clip should appear 1000ms into the main timeline. Right now it jsut appears … 0ms into the main timeline. Any ideas?

Thank you in advance 🙂
