Stick Page Forums Archive

Play and REplay button.[Flash][Buttons]

Started by: vml | Replies: 4 | Views: 2,487

vml
2

Posts: 266
Joined: Mar 2012
Rep: 10

View Profile
Apr 5, 2012 12:08 PM #628090
I know a lot of people know about this code but i'm posting this for all the begginers (like me LoL) in coding ^^

just to make it clear i'm using AS2

well let's get this started

Like in all the buttons tutorial go to library--common library--buttons just if you DON'T have a button with your own design


[ATTACH=CONFIG]3114[/ATTACH]

select the one you like from this library

when you have the button you like you're ready for the codes: this code goes in the button:

on (press) {
play();
}

[ATTACH=CONFIG]3115[/ATTACH]


with the REplay button you have to follow all the steps again the only different thing is the code, replay code: obviously in other button.

on (press) {
gotoAndPlay(2);
}

in the first frame of your movie and the last where you put the buttons you need to put this code in the actions panel (F9): stop(); or the movie will play and all this work will be in vain, ok?

[ATTACH=CONFIG]3116[/ATTACH]

well I think that's all see you next time

Bye, vml..........
ridersaber
Banned

Posts: 136
Joined: Apr 2012
Rep: 10

View Profile
Apr 23, 2012 9:45 AM #640792
thank you vml for the tutorial
XD
vml
2

Posts: 266
Joined: Mar 2012
Rep: 10

View Profile
Apr 23, 2012 11:14 PM #641328
no problem "ridersaber" i'm here to help
stone

Posts: 1,959
Joined: Mar 2008
Rep: 10

View Profile
Apr 26, 2012 4:27 PM #643161
I think you should point out that this is AS2 and not AS3 somewhere in the upper portion of the tutorial. Some people might start this and not get the desired results due to the wrong actionscript version.
vml
2

Posts: 266
Joined: Mar 2012
Rep: 10

View Profile
Nov 23, 2012 3:20 AM #795132
I Completely Forgoted this Tut....
Website Version: 1.0.4
© 2025 Max Games. All rights reserved.