-
1. Re: Next & back button
vivekuma Dec 2, 2014 6:05 AM (in response to iHuseyin)You can have an array of labels with the time-position, and maintain an index , and do the following:
//Add this in the compositionReady of stage
sym.labelArray = {"lable1": 5000, "lable2": 10000, "lable3": 15000, "lable4": 20000, "lable5": 25000}
sym.index = 0;
//Add this in the next button click event handler:
if (sym.index < sym.labelArray.length) {
sym.play(sym.labelArray[sym.index]);
sym.index = sym.index + 1;
}
//Add this in the previous button click event handler:
if(sym.index > 0) {
sym.play(sym.labelArray[sym.index]);
sym.index = sym.index - 1;
}
Note: You need to have a trigger at all those label like : sym.stop();
hth,
Vivekuma
-
2. Re: Next & back button
iHuseyin Dec 2, 2014 11:45 PM (in response to vivekuma)it seemed very easy but somehow I'm missing something or can't do it properly. I really appreciate a lil help and do pardon my lack of coding knowledge. I am a designing professional and I have almost 'ZERO' knowledge of codes but I'm very keen to learn this...
Lets say, I have 3 boxes in the stage. 2 buttons named "next" and "back". I have animated them using the timeline (just going from right to left ) and I've put labels 1,2,3 at each steps I want them to animate by each clicks. I have put triggers at the beginning, at the end and in bitwin those using sym.stop(). Now I need the animation to go to the next state every time I click next button like 1 - 2 - 3 so on .... and when pressing the back button going back 3 - 2 - 1.
OH! how hard it can be ?!!!! I desperately need tutorial...vivekuma
-
3. Re: Next & back button
vivekuma Dec 3, 2014 12:09 AM (in response to iHuseyin)Check this out @ https://www.dropbox.com/s/znc49bs45zeazt6/3Buttons.rar?dl=0
Have created a simple composition to illustrate.
hth,
Vivekuma
-
4. Re: Next & back button
iHuseyin Dec 3, 2014 2:26 AM (in response to vivekuma)Thanks a lot!!!! It's helping me to understand the process..
-
5. Re: Next & back button
HIwei Dec 3, 2014 6:12 AM (in response to iHuseyin)You may try to add a few labels and use "jump"...



