[SIZE=1]Sorry for duplicating the tread.[/SIZE]
Hi all,
I have a function that goes like this;
function goback1(event:Event) {
cont.nums.y=86.5;
var gnerden=cont.nums._1Ocak.height;
var gynerden=cont.nums._1Ocak.y;
var gynereye=cont.nums._1Ocak.y+15;
var gbnerden=cont.nums.myback1.y;
var gbnereye=cont.nums.myback1.y+15;
var load1tw:Tween=new Tween(cont.nums._1Ocak,"height",Regular.easeOut,gnerden,30,1,true);
var load2tw:Tween=new Tween(cont.nums._1Ocak,"y",Regular.easeOut,gynerden,gynereye,1,true);
var bgtw:Tween=new Tween(cont.nums.myback1,"height",Regular.easeOut,cont.nums.myback1.height,0,1,true);
var bgtw2:Tween=new Tween(cont.nums.myback1,"y",Regular.easeOut,gbnerden,gbnereye,1,true);
}
my problem is, i have more than 20 buttons, and i have 20 copies of this same code for all those buttons.
according to my limited knowladge with c++, i should pass the object as the parameter and use the same code for 20 buttons.
how can i do that?
i tried function goback1(object:event.Object) or (object:event.this) but they didn’t work.