Hey there! I was wondering if someone could help me along with a code I've been working with for a game, it's a unit queue system which allows a user to select units and queue them up for creation.

So far it works pretty well, the SWF is here for you to see:
http://www.liquid-visual.com/panel6.html

All you need to do is click one of the boxes to the left for them to queue on the right. The code I'm using is;

Code:
var currentBox = 1;
function fillBox(labelName) {
	_parent["box"+currentBox].gotoAndStop(labelName);
	currentBox++;
}
adam.onRelease = function() {
	fillBox("adam");
	_parent.compiler.play();
};
eve.onRelease = function() {
	fillBox("eve");
	_parent.compiler.play();
};
spectre.onRelease = function() {
	fillBox("spectre");
	_parent.compiler.play();
};
What I'm trying to do now is shift the boxes up one space once a box is finished creating. I'm aiming to do this with the load bar.

The idea is that inside the MC of the loading bar, at the end of the load (on the final frame) - if the first box's current frame equals a certain unit, that unit will place itself somewhere on the movie canvas..perhaps randomly, but that's further down the track.

My QUESTION now is how would I go about making it so that after the loading bar finishes it's animation it clears box1 (frame 1 / label; "none") and the next box moves into its place, and so forth. ?

So once box1 finishes, box2 moves into box1 and box3 moves into box2 etc etc

A little more complicated, just hope it's possible!

http://www.liquid-visual.com/panel5.fla I've uploaded the FLA if it makes it easier to see what I'm doing.

Thanks!