So i have a menu with buttons, which are actually a single mc, of which i have multiple instances on the stage and i change their text on startup via AS. I also have rollover, rollout and of course onrelease events. Rollover and rollout are the same for all elements so if i include them as a part of the element MC it works without problem. But that occurs when implementing onrelease event to open a new page.
I cant put it into the mc because it opens different pages (or is there a way?) and if i try to define it in _root the other 2 events dont work anymore. The only solution i found so far is defining events for each of the elements like this:
this.m0.onRelease = function(){
getURL("index.php?p=0", "_self");
};
this.m0.onRollOver = function(){
showSparkles(m0);
};
this.m0.onRollOut = function(){
endSparkles();
};
but im sure theres a better way (in a loop for example) to do this. If i do try putting it in a loop i cant (well… dont know how:azn:) getting the current rolledover element to the showSparkles function.
Any help please?