This is my problem that I have been fighting for way too long. I have a grid with some 300 boxes in it. I want these boxes to populate the grid randomly with random number of boxes populating each time.
My grid is a MC and all of the squares in it are the child of a another MC. All squares are named 1-300 and as you can see in the array, I am testing just 18 right now.
I am hoping that it is possible to do what I want to do with an array because I think it would save me a lot of time and save computers a lot of processor juice.
I have been able to get the setProperty to affect the squares that the array points to, but it won’t move on to any other squares. Or it will make the entire MC invisible.
I would REALLY apreciate some help on this one.
CODE for frame 1:
//This code should wipe the grid clean
Boxes = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18];
for (count = 0; count<=18; count++) {
        setProperty(Boxes[count], _visible, false);
}
CODE for frame 2:
//This should randomly polulate the grid
var RanBox; //Random Box Movie Clip
var MaxTimes; //Limit of times runable
trace (MaxTimes = random(5));
for (TR = 0; TR<=MaxTimes; TR++) { //Times Run
        RanBox = random(1:cool: ;
        setProperty(Boxes[RanBox], _visible, true);
}
stop;
If you’re reading this now, YOU’RE A ROCK STAR because I was sure that I would have lost most peoples attention by now. If you come up with a solution, you’re a Flash Diety (much better than a rock star).