This content has been marked as final. Show 3 replies
this is going to depend on the structure of the rest of your document and 'where' this code is located. usually we would write this a little differently as well, to control the call of the method a little better. It may be that you need to add a condition to the method which will determine if the 'home' button has been called or not - but again this will depend on exactly 'how' you are controlilng things and where this code resides. It would be something more like this:
thanks i'll try something similar,
the problem is i'm not working with different scenes, its all within one, so the fade works
can 'home' be the linkage identifier of a button?
yes it sure could be an instance name of a button. however in the code I'd constructed there 'destination' would be a string variable and when a button is pressed you would first set the var to a value related to the button (like 'home' as an example) and I was assuming that you may be using frame 'labels' to navigate to the sections - not scenes - scenes=bad news - lol!
but yes you could use the instance name of a button by passing it to the method from each button - then in the method you would use the same type of condition but compare it to the name passed in, as in the following