Calling a function :-X

Arrrrggggggghhh… :m:

I am just going nuts now…i forgot basic stuff like functions ! OMG :hr:

Please help me…I am trynna call resz function with a on(release) event handler, but it doesnt work ! :a:

_root.onEnterFrame = resz;
resz = function (x, y) {
butx = base._x-base._width/2;
buty = base._y-base._height/2;
menu._x = Math.round(butx-menu._width+10);
menu._y = Math.round(buty+30);
xo = Math.round(this.base._width);
yo = Math.round(this.base._height);
xns = Math.round(xo+((x-xo)/9));
yns = Math.round(yo+((y-yo)/9));
this.base._width = Math.round(xns);
this.base._height = Math.round(yns);
this.sha._width = Math.round(xns);
this.sha._height = Math.round(yns);
};
stop();


calling resz function

on(release) { _root.resz(100,200); }

Problem : The button calls resz function just one time !, i wanna make it so that it repeats on entering a frame (onEnterFrame) …

I tried,

onEnterFrame.resz = function(x,y) { blah blha blah }

&

onEnterFrame = function resz(x,y) { balhbgbosigb }

but , blablhnbalnl doesnt execute ! , and if it does, then only once…:frowning: