# Fps (urgent)

**URL:** <https://forum.kirupa.com/t/fps-urgent/8896>\
**Category:** Uncategorized\
**Created:** [November 30, 2002, 7:01pm UTC](https://forum.kirupa.com/t/fps-urgent/8896 "2002-11-30T19:01:09Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![novatake](https://avatars.discourse-cdn.com/v4/letter/n/e47774/32.png) [@novatake](https://forum.kirupa.com/u/novatake)\
**Post date:** [November 30, 2002, 7:01pm UTC](https://forum.kirupa.com/t/fps-urgent/8896/1 "2002-11-30T19:01:09Z")

</div>

just a quick question kinda urgent is there a way of making the fps of parts of a movie e.g. the buttons faster than the rest i need my buttons to fade fast but the rest of it a little slower

-Tom

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [November 30, 2002, 7:30pm UTC](https://forum.kirupa.com/t/fps-urgent/8896/2 "2002-11-30T19:30:28Z")

</div>

well… not that I know of… I think the only way is to make one animation longer, the other shorter or was it… the other way around! Well… one has more frames and the other less… 🙂

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [November 30, 2002, 8:40pm UTC](https://forum.kirupa.com/t/fps-urgent/8896/3 "2002-11-30T20:40:53Z")

</div>

Its possible with this lil tid bit of code:

```php
function playNextFrame() {
	_parent.nextFrame();
}
setInterval(playNextFrame, 2000/2000 ); 

```

Convert your buttons to movieclips then place that code on a new layer and on the first frame. As of right now the code is set at 2000 fps so adjust the numbers to whatever suits you. I attached a simple fla to help you see what I’m talking about. Hope it helps. =)

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [November 30, 2002, 8:41pm UTC](https://forum.kirupa.com/t/fps-urgent/8896/4 "2002-11-30T20:41:46Z")

</div>

Dammit, i forgot the fla…  
Here it is. =)

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [November 30, 2002, 8:43pm UTC](https://forum.kirupa.com/t/fps-urgent/8896/5 "2002-11-30T20:43:49Z")

</div>

ahhh! why didn’t think of that???

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [December 1, 2002, 12:38am UTC](https://forum.kirupa.com/t/fps-urgent/8896/6 "2002-12-01T00:38:38Z")

</div>

Here is a handy one and easy to use:

Put this script in ur \_root timeline:

```php
// Set the FPS you've set in Flashmovie...
_root.orgFPS = 40;

function internal(sender) {
     if (sender._currentframe == sender._totalframes) {
          sender.gotoAndStop(1);
     }
     sender.nextFrame();
     updateAfterEvent();
}

MovieClip.prototype.play = function(fps) {
     if (!fps) fps = _root.orgFPS+2;
     fps = 1000/fps;
     unique = setInterval( _root.internal, fps, this);
}

MovieClip.prototype.stop = function() {
     clearInterval( unique );
}

```

(\*\* Usage: \*\*)

```php
MovieClip.play(fps);//set ur fps here :)
MovieClip.stop();

```

Hope it helps,

yours,  
h88

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [December 1, 2002, 1:58pm UTC](https://forum.kirupa.com/t/fps-urgent/8896/7 "2002-12-01T13:58:42Z")

</div>

cheers guys thats wot i was lookin for i aint must of a scripter
