|
-
problem passing a variable
I am trying to pass this variable to an array and play the contents of the array from a button. But so far to no avail. Can anyone tell me if im even on the right track here?
(the variable, created when a button is pressed...is what Im trying to do)
on (press) {
startDrag(tile_i);
this = tile;
tile.attachSound("I.mp3");
}
on (release) {
stopDrag();
if (tile_i._droptarget == tile_1.DropZone)
//trace("test");
soundSeq.push("tile"); //to send the variable to the array
}
--------------
(the array and play function)
soundSeq = Array();
_root.button.onRelease = function() {
for (z=0; z<soundSeq; ++z) { // I figure this will play the array
soundSeq[z].play();
}
};
Thanks in advance for any pointers!
Mark
-
FK'n_dog
soundSeq = Array();
use - soundSeq = new Array();
or - soundSeq = [];
and - for (var z=0; z<soundSeq.length;z++)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|