This content has been marked as final. Show 3 replies
This is not the best way to do it, you know why? Because you can never predict which one is going to run first, the onRelease placed on the button, or the mouseUp placed on the content. Even if you can, the player might change the rules in the future. So the first time runs your onMouseUp first and then the onRelease, so when the onMouseUp runs the variables are not set yet. The second time you click the vars are already set because of the previous click and the mouseUp works.
It is not good to place the code in two different places try placing it all inside the buttons. If the code repeats itself a lot try placing it on a function like the code I am sending you.
I have kept the first line after every on(release) not because it is necesary but because I don´t know if you are needing this for other purposes. If you see you don´t really need it, you can delete this line manually:
This code calls a function when pressing the buttons. I created a variable that holds the currently selected content, so when you press a button you place the current content to frame 1, then set the current content to be the content you are selecting, finally you place the now current content to frame 2 and further:
It makes sense. I will have to wait unfortunately until Monday to try it out. If I have additional problems can I email you? OR do you check through your posts | replies routinely?