
I building a photoviewer with xml loaded pics…
my problem right now is that i should building the back button, but i dont know how …
it should be:
when i press back-button(mc) (its placed on frame 10 to frame 20)
it should gotoandplay frame 21
and when its hits frame 30
it should read, if back-button was clicked it should play frame 50, if not it should play frame 31.
in other words…
i assume that i should have a "gotoAndPlay(21)" on the frame 10 to 20, where the back-button are.
and on frame 30, i shoul have a addEventListener witch listening if the back-button has been clicked.
And then there should be a function says;
if back-button cliked
gotoAndPlay(50)
else gotoAndPlay(31);
anybody there can help me with my problem..:) PLEASE….
thx
If you would like to make a comment, please fill out the form below.
Add a var:
var pressedBack = true; (when you press the button)
then on the check
if (pressedBack) {
// do what you like if it’s pressed
} else {
// do the other thing
}
// dont forget:
pressedBack = false;