Ver Mensaje Individual
  #6 (permalink)  
Antiguo 17/08/2005, 10:45
Avatar de TMeister
TMeister
Crazy Coder
 
Fecha de Ingreso: enero-2002
Ubicación: En la Oficina
Mensajes: 2.880
Antigüedad: 22 años, 3 meses
Puntos: 193
Quieres algo como esto:

Código:
var col:Number = 5;
var count:Number = 1;
var basex:Number = 0;
var basey:Number = 0;
function init() {
	doIt = setInterval(make, 500);
}
function make() {
	if (van<cantidad) {
		var clip_mc:MovieClip = makeBox("b"+van);
		clip_mc._x = basex;
		clip_mc._y = basey;
		if (count == col) {
			basex = 0;
			basey += Math.round(clip_mc._height);
			count = 1;
		} else {
			basex += Math.round(clip_mc._width);
			count++;
		}
		van++;
	} else {
		clearInterval(doIt);
	}
}
function makeBox() {
	var temp_mc:MovieClip = createEmptyMovieClip(name, _root.getNextHighestDepth());
	temp_mc.lineStyle(0, 0xffffff);
	temp_mc.beginFill(0xd4d4d4);
	temp_mc.lineTo(0, 0);
	temp_mc.lineTo(30, 0);
	temp_mc.lineTo(30, 30);
	temp_mc.lineTo(0, 30);
	temp_mc.lineTo(0, 0);
	return temp_mc;
}
init();
Cipoa pega y Prueba..