Search Tutorials
For our normal movement we declare that the fastmove variable equals 1 and our mc will play from the "normal" frame. on (release) {
fastmove = 1;
gotoAndPlay ("normal");
}
on (release) {
fastmove = 1;
gotoAndPlay ("reverse");
}
For stop the mc stops to "stop" frame. on (release) {
gotoAndStop ("stop");
}
The next 2 buttons are used to increase and decrease the speed variable. on (release) {
if (speed>100) {
speed = speed-100;
}
}
The if statement is used so the speed variable will always be above 0. on (release) {
speed = speed+100;
}
When speed variable increases the speed of our movie decreases.
The double forward and backward button give fastmove variable a value of 5 and move the mc to "normal" and "reverse" frames. on (release) {
fastmove = 5;
gotoAndPlay ("normal");
}
And: on (release) {
fastmove = 5;
gotoAndPlay ("reverse");
}
And with that we have finished with the inside of our control mc. It's time to put it in our stage.
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
![]() |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|