View Full Version : MC Speed
deep cover
May 29th, 2002, 10:15 PM
How can I have an MC play at different speeds upon a button click. For example, I want button one to play the MC "cars" at one speed, and button two to play the same MC (cars) at another speed? Thanks in advance...
I am not Jubba
May 29th, 2002, 10:21 PM
set variables. have the movieclips move at the speed "nSpeed" and then when the buttons are pressed change the values of "nSpeed"
or do you mean different FPS? cuz thats not easy, Sinf had a way to do it, but its very complicated.
deep cover
May 29th, 2002, 10:36 PM
Ok, I wanted different FPS, but how do I change the values of nSpeed upon different clicks of a button?
I am not Jubba
May 29th, 2002, 10:41 PM
on(press){
nSpeed = 4
}
and on a different button would be
on(press){
nSpeed = 9
}
you could use this when moving movieclips. the code on a movie clip would look something like this.
onClipEvent(enterFrame){
this._x += nSpeed
}
this would move the movieclip to the right with a speed of "nSpeed"
deep cover
May 29th, 2002, 11:13 PM
Thank you so much. That was great information you provided.
Powered by vBulletin® Version 4.1.10 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.