AS2 connect navigation


/ Published in: ActionScript
Save to your folder(s)



Copy this code and paste it in your HTML
  1. var i:Number = 0;
  2. var nav_buttons:Array = [name1,name2];
  3.  
  4. ///// make interactive
  5. for (i;i<nav_buttons.length;i++)
  6. {
  7. nav_buttons[i].onRelease = function()
  8. {
  9. switch(this._name)
  10. {
  11. case "name1": doSomething(); break;
  12. case "name2": doSomething(); break;
  13. }
  14. }
  15. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.