Page 2 of 2

Re: setLabelClickCallback("mtar1", matt() )

Posted: Tue Jan 05, 2010 10:23 pm
by Vadi
Hmm. Did anything come out of this?

Re: setLabelClickCallback("mtar1", matt() )

Posted: Tue Aug 24, 2010 12:56 pm
by Naito
EDIT: Scratch that... Question is nul and void >.> Seems I fixed the problem myself.

Re: setLabelClickCallback("mtar1", matt() )

Posted: Tue Aug 24, 2010 1:03 pm
by Naito
I hope this is a good thread to ask this.

How would a setLabelClickCallBack work? Heres what I have:
Code: [show] | [select all] lua
createLabel("Stupidity",960,97,90,30,1);
  moveWindow("Stupidity",1000,97,90,30,1)
  setLabelClickCallback("Stupidity","Eat_Lung")
  setLabelStyleSheet("Stupidity", [[background-image: url(]]..gfx_path .. "GreenButton.png"..[[);]])

ALIAS: Eat_Lung

CODE: send("outc lung slice")
send("eat lung_slice")
But it doesn't come up with any kind of error or the like for it not working, doesn't do anything when I attempt to click the label either. I'm going to try and make a function that eats lung slice and see if that works. But thus far nothing is happening

EDIT: With the new function made called 'Eat_Lung()' it comes back with the following error:[ERROR:] object:<event handler function> function:<Eat_Lung()>