-
As stated, the only code for the buttons is contained in the on(press) handler (and that is the myArray.push() stuff)
-
You will no longer need a variable, you will have to store the new info into the array and then when you are ready you parse that array into a string (one of my posts has an example of that)
-
Since you will be using an array and not a variable you will have to target the name of your array.
-
No, prototype functions are Object specific functions (MovieClip.prototype, Button.prototype, Array.prototype, String.prototype, etc) so it will stay as Array.prototype. here is a kirupa.com tutorial on prototypes…
http://www.kirupa.com/developer/actionscript/tricks/prototypes.htm
-
You change the myArray part to whatever name you assign to your array, and you change the myString part to whatever name you want to assign the final output string.
-
You put all of the code on a frame (since you are new to AS I would say preferably the _root timeline) EXCEPT the on(press) stuff, that code will go on your buttons.
To be able to do something of this magnitude it is VERY important that you have knowledge of functions, prototypes, arrays/array manipulation and for loops. I recommend reading up on those because they are needed for this, and will become VERY handy in the future if you need them.