Ciao a tutti.Ho un problema che magari non lo è.Adesso mi spiego meglio, ho creato questo componente d'esempio,e vorre che si possa attaccare dalla libreria, con un oggetto iniziale,senza che l'utente debba sapere, a nomi delle variabili( _basename...),senza a dover eseguire il metodo attackAll().Per il momento ho impostato cosi.
this.attachMovie('mc', 'mc_uno', 0);
mc_uno.attackAll('base', 'back', 'front');
// qusto vorrei evitare
this.attachMovie('mc', 'mc_uno', 0,{20,_basename:'base',_frontname:'front',_backnam e:'back'});
codice:
#initclip
function Myclass()
{
	this.init(this.base, this._basename, this._frontname, this._backname);
}
Myclass.prototype = new MovieClip();
Object.registerClass("mc", Myclass);
Myclass.prototype.setBase = function(b)
{
	this.base = b;
};
Myclass.prototype.attackBase = function(clip)
{
	this.base_mc.attachMovie(clip, 'sub_base', 1);
};
Myclass.prototype.attackFrontGround = function(clip)
{
	this.front_mc.attachMovie(clip, 'sub_front', 1);
};
Myclass.prototype.attackBackGround = function(clip)
{
	this.back_mc.attachMovie(clip, 'sub_back', 1);
};
Myclass.prototype.init = function(a, b, c, d)
{
	this.setBase(a);
	this.attackBase(b);
	this.attackFrontGround(c);
	this.attackBackGround(d);
};
Myclass.prototype.attackAll = function(a, b, c)
{
	this.attackBase(a);
	this.attackFrontGround(b);
	this.attackBackGround(c);
};
#endinitclip
secondo voi si po fare ,grazie mille in anticipo